Download the PHP package ock/class-files-iterator without Composer
On this page you can find all versions of the php package ock/class-files-iterator. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package class-files-iterator
Class files iterator
This package provides IteratorAggregate implementations to iterate through class files.
Main concepts:
ClassFilesIA*
:\ IteratorAggregate that lists class names keyed by their file names.NamespaceDirectory
:\ Main implementation representing a PSR-4 class files directory.\ It provides additional methods to navigate to parent or child directories.
ClassNamesIA*
\ IteratorAggregate that lists class names by numeric keys.\ This can be used if the file path is not relevant.
Benefits
There are other packages which attempt to solve the same problem in different ways.
The benefits of this package are:
- Predictable (alphabetic) order of class files.\
This is thanks to internal usage of
scandir()
with sort flag, instead of directory iterators. - The "iterators" are stateless/immutable, and can be passed around as value objects.\
This is thanks to them extending
IteratorAggregate
instead ofIterator
. - Code that needs a list of classes or class files can simply depend on the interfaces, and does not need to deal with directories.
Limitations
Iterators for reflection classes are not part of this package.
Usage
All versions of class-files-iterator with dependencies
PHP Build Version
Package Version
The package ock/class-files-iterator contains the following files
Loading the files please wait ....