function Finder::path
Adds rules that filenames must match.
You can use patterns (delimited with / sign) or simple strings.
$finder->path('some/special/dir') $finder->path('/some\/special\/dir/') // same as above $finder->path(['some dir', 'another/dir'])
Use only / as dirname separator.
Parameters
string|string[] $patterns A pattern (a regexp or a string) or an array of patterns:
Return value
$this
See also
File
-
vendor/
symfony/ finder/ Finder.php, line 261
Class
- Finder
- Finder allows to build rules to find files and directories.
Namespace
Symfony\Component\FinderCode
public function path(string|array $patterns) : static {
$this->paths = array_merge($this->paths, (array) $patterns);
return $this;
}