Property | Type | Description | |
---|---|---|---|
$_exclude | array | List of exclude patterns | |
$_include | array | List of include patterns | |
$_types | array | List of allowed types |
Method | Description | |
---|---|---|
_dirFlags ( array $options ) : integer | Returns FilesystemIterator flags from Dir options. | |
_iteratorFlags ( array $options ) : integer | Returns RecursiveIteratorIterator flags from Dir options. | |
accept ( ) : boolean | Checks if a file passes the setted filters. | |
copy ( array | string $path, string $dest, array $options = [] ) : array | Copies a directory. | |
filter ( array $options = [] ) | Applies some filters to a FilterIterator instance. | |
make ( array | string $path, array $options = [] ) : boolean | Creates a directory. | |
remove ( array | string $path, array $options = [] ) | Removes one or many directories. | |
scan ( array | string $path, array $options = [] ) : array | Scans one or many directories for files. | |
tempnam ( string $path = null, string $prefix = '' ) : string | Creates a directory with unique file name. |
Method | Description | |
---|---|---|
_copy ( string $path, string $dest, array $options ) : array | Copies a directory. | |
_excluded ( $path ) : boolean | Checks if a file passes match an excluded path. | |
_included ( $path ) : boolean | Checks if a file passes match an included path. | |
_matchType ( ) : boolean | Checks if a file passes match the allowed type. | |
_scan ( string $path, array $options, $dirFlags, $iteratorFlags ) : array | Scans a given directory for files. |
protected static _copy ( string $path, string $dest, array $options ) : array | ||
$path | string | Source directory. |
$dest | string | Destination directory. |
$options | array | Scanning options. Possible values are: -`'mode'` _integer_ : Mode used for directory creation. -`'childrenOnly'` _boolean_ : Excludes parent directory if `true`. -`'followSymlinks'` _boolean_ : Follows Symlinks if `true`. -`'recursive'` _boolean_ : Scans recursively if `true`. -`'include'` _string|array_: An array of includes. -`'exclude'` _string|array_: An array of excludes. |
return | array |
public static _iteratorFlags ( array $options ) : integer | ||
$options | array | Scanning options. Possible values are: -`'iterator'` _integer_ : The iterator mode. -`'leavesOnly'` _boolean_ : Keeps only leaves if `true`. |
return | integer | Some `RecursiveIteratorIterator` flags |
protected _matchType ( ) : boolean | ||
return | boolean | Returns `true` if match the allowed type, `false` otherwise. |
protected static _scan ( string $path, array $options, $dirFlags, $iteratorFlags ) : array | ||
$path | string | Path or paths to scan. |
$options | array | Scanning options. Possible values are: -`'iterator'` _integer_ : The iterator mode. -`'skipDots'` _boolean_ : Keeps '.' and '..' if `true`. -`'leavesOnly'` _boolean_ : Keeps only leaves if `true`. -`'followSymlinks'` _boolean_ : Follows Symlinks if `true`. -`'recursive'` _boolean_ : Scans recursively if `true`. -`'include'` _string|array_: An array of includes. -`'exclude'` _string|array_: An array of excludes. -`'type'` _string|array_: An array of types. |
return | array |
public static copy ( array | string $path, string $dest, array $options = [] ) : array | ||
$path | array | string | Source directory. |
$dest | string | Destination directory. |
$options | array | Scanning options. Possible values are: -`'mode'` _integer_ : Mode used for directory creation. -`'childrenOnly'` _boolean_ : Excludes parent directory if `true`. -`'followSymlinks'` _boolean_ : Follows Symlinks if `true`. -`'recursive'` _boolean_ : Scans recursively if `true`. |
return | array |
public static scan ( array | string $path, array $options = [] ) : array | ||
$path | array | string | Path or paths to scan. |
$options | array | Scanning options. Possible values are: -`'iterator'` _integer_ : The iterator mode. -`'skipDots'` _boolean_ : Keeps '.' and '..' if `true`. -`'leavesOnly'` _boolean_ : Keeps only leaves if `true`. -`'followSymlinks'` _boolean_ : Follows Symlinks if `true`. -`'recursive'` _boolean_ : Scans recursively if `true`. -`'include'` _string|array_: An array of includes. -`'exclude'` _string|array_: An array of excludes. -`'type'` _string|array_: An array of types. |
return | array |