Skip to content

Commit 5b79d39

Browse files
committed
Add create shortcut
1 parent 005f95b commit 5b79d39

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

src/deit/filesystem/Finder.php

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,16 @@ class Finder implements \IteratorAggregate, \Countable {
1818
const TYPE_FILE = 'files';
1919
const TYPE_FOLDER = 'folders';
2020

21+
/**
22+
* Creates a new finder
23+
* @param string $path The path to search
24+
* @return Finder
25+
* @throws
26+
*/
27+
public static function create($path) {
28+
return new self($path);
29+
}
30+
2131
/**
2232
* The path to search in
2333
* @var string
@@ -199,4 +209,4 @@ public function count() {
199209
}
200210

201211
}
202-
212+

0 commit comments

Comments
 (0)