8000 minor #12059 [Finder] Add info about possibilities offered by SplFile… · symfony/symfony@c8daa9c · GitHub
[go: up one dir, main page]

Skip to content

Commit c8daa9c

Browse files
committed
minor #12059 [Finder] Add info about possibilities offered by SplFileInfo (ywarnier)
This PR was submitted for the master branch but it was merged into the 2.3 branch instead (closes #12059). Discussion ---------- [Finder] Add info about possibilities offered by SplFileInfo Minor documentation improvement Commits ------- b2219cf [Finder] Add info about possibilities offered by SplFileInfo
2 parents d002f17 + b2219cf commit c8daa9c

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/Symfony/Component/Finder/README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ Finder finds files and directories via an intuitive fluent interface.
1818
print $file->getRealpath()."\n";
1919
}
2020

21+
The resulting contents of the iterator are instances of [SplFileInfo][1]. You can
22+
thus use all of SplFileInfo's methods (getPerms(), getSize(), etc) on them. See
23+
[the API documentation][2] or the [web tutorial][3] for more.
24+
2125
But you can also use it to find files stored remotely like in this example where
2226
we are looking for files on Amazon S3:
2327

@@ -39,3 +43,6 @@ You can run the unit tests with the following command:
3943
$ composer.phar install
4044
$ phpunit
4145

46+
[1]: http://php.net/splfileinfo
47+
[2]: http://api.symfony.com/2.5/Symfony/Component/Finder/SplFileInfo.html
48+
[3]: http://symfony.com/doc/current/components/finder.html#usage

0 commit comments

Comments
 (0)
0