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 and directories matching mask.
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 60
static Finder
find(string|string[] ...$masks)
Begins search for files and directories matching mask.
at line 72
static Finder
findFiles(string|string[] ...$masks)
Begins search for files matching mask.
at line 84
static Finder
findDirectories(string|string[] ...$masks)
Begins search for directories matching mask.
at line 113
Finder
in(string|string[] ...$paths)
Searches in the given folder(s).
at line 125
Finder
from(string|string[] ...$paths)
Searches recursively from the given folder(s).
at line 141
Finder
childFirst()
Shows folder content prior to the folder.
at line 184
int
count()
Get the number of found files and/or directories.
at line 193
Iterator
getIterator()
Returns iterator.
at line 268
Finder
exclude(string|string[] ...$masks)
Restricts the search using mask.
Excludes directories from recursive traversing.
at line 287
Finder
filter(callable $callback)
Restricts the search using callback.
at line 298
Finder
limitDepth(int $depth)
Limits recursion level.
at line 310
Finder
size(string $operator, int|null $size = null)
Restricts the search by size.
at line 334
Finder
date(string $operator, string|int|DateTimeInterface $date = null)
Restricts the search by modified time.
at line 355
static bool
compare($l, string $operator, $r)
Compares two values.
at line 382
__call(string $name, array $args)
No description
at line 390
static void
extensionMethod(string $name, callable $callback)
No description
Traits
Strict class for better experience.