The filtered array is returned. This array preserves the keys of the
passed array.
php
$filteredPaths = Glob::filter($paths, '/project/**.twig');
public static filter ( array $paths, string $glob, integer $flags = self::FILTER_VALUE ) : string[] | ||
$paths | array | A list of paths. |
$glob | string | The canonical glob. The glob should contain forward slashes as directory separators only. It must not contain any "." or ".." segments. Use the "webmozart/path-util" utility to canonicalize globs prior to calling this method. |
$flags | integer | A bitwise combination of the flag constants in this class. |
return | string[] | The paths matching the glob indexed by their original keys. |