Finder
class Finder implements IteratorAggregate, Countable
Finder allows searching through directory trees using iterator.
Finder::findFiles('*.php')
->size('> 10kB')
->from('.')
->exclude('temp');
Methods
Begins search for files matching mask and all directories.
Begins search for directories matching mask.
Shows folder content prior to the folder.
Get the number of found files and/or directories.
Returns iterator.
Limits recursion level.
Restricts the search by modified time.
Compares two values.
No description
No description
Details
at line 58
static Finder
find(string|string[] ...$masks)
Begins search for files matching mask and all directories.
at line 70
static Finder
findFiles(string|string[] ...$masks)
Begins search for files matching mask.
at line 82
static Finder
findDirectories(string|string[] ...$masks)
Begins search for directories matching mask.
at line 111
Finder
in(string|string[] ...$paths)
Searches in the given folder(s).
at line 123
Finder
from(string|string[] ...$paths)
Searches recursively from the given folder(s).
at line 138
Finder
childFirst()
Shows folder content prior to the folder.
at line 177
int
count()
Get the number of found files and/or directories.
at line 186
Iterator
getIterator()
Returns iterator.
at line 258
Finder
exclude(string|string[] ...$masks)
Restricts the search using mask.
Excludes directories from recursive traversing.
at line 276
Finder
filter(callable $callback)
Restricts the search using callback.
at line 287
Finder
limitDepth(int $depth)
Limits recursion level.
at line 299
Finder
size(string $operator, int $size = null)
Restricts the search by size.
at line 322
Finder
date(string $operator, string|int|DateTimeInterface $date = null)
Restricts the search by modified time.
at line 341
static bool
compare($l, string $operator, $r)
Compares two values.
at line 368
__call(string $name, array $args)
No description
at line 376
static void
extensionMethod(string $name, callable $callback)
No description
Traits
Strict class for better experience.