Directory
extends RecursiveDirectoryIterator
in package
Class \Hoa\Iterator\Recursive\Directory.
Extending the SPL RecursiveDirectoryIterator class.
Tags
Table of Contents
Properties
- $_relativePath : string
- Relative path.
- $_splFileInfoClass : string
- SplFileInfo classname.
- $_handlePath : string
- Workaround for the bug #65136.
Methods
- __construct() : mixed
- Constructor.
- current() : mixed
- Current.
- getChildren() : mixed
- Get children.
- getRelativePath() : string
- Get relative path (if given).
- setSplFileInfoClass() : void
- Set SplFileInfo classname.
Properties
$_relativePath
Relative path.
protected
string
$_relativePath
= 0
$_splFileInfoClass
SplFileInfo classname.
protected
string
$_splFileInfoClass
= null
$_handlePath
Workaround for the bug #65136.
private
static string
$_handlePath
= null
Methods
__construct()
Constructor.
public
__construct(string $path[, int $flags = null ][, string $splFileInfoClass = null ]) : mixed
Please, see \RecursiveDirectoryIterator::__construct() method. We add the $splFileInfoClass parameter.
Parameters
- $path : string
-
Path.
- $flags : int = null
-
Flags.
- $splFileInfoClass : string = null
-
SplFileInfo classname.
current()
Current.
public
current() : mixed
Please, see \RecursiveDirectoryIterator::current() method.
getChildren()
Get children.
public
getChildren() : mixed
Please, see \RecursiveDirectoryIterator::getChildren() method.
getRelativePath()
Get relative path (if given).
public
getRelativePath() : string
Return values
stringsetSplFileInfoClass()
Set SplFileInfo classname.
public
setSplFileInfoClass(string $splFileInfoClass) : void
Parameters
- $splFileInfoClass : string
-
SplFileInfo classname.