PHP Class org\bovigo\vfs\visitor\vfsStreamStructureVisitor

See also: https://github.com/mikey179/vfsStream/issues/10
Since: 0.10.0
Inheritance: extends vfsStreamAbstractVisitor
Show file Open project: mikey179/vfsstream Class Usage Examples

Protected Properties

Property Type Description
$current poiting to currently iterated directory
$structure collected structure

Public Methods

Method Description
__construct ( ) constructor
getStructure ( ) : array returns structure of visited contents
reset ( ) : vfsStreamStructureVisitor resets structure so visitor could be reused
visitBlockDevice ( org\bovigo\vfs\vfsStreamBlock $block ) : vfsStreamStructureVisitor visit a block device and process it
visitDirectory ( vfsStreamDirectory $dir ) : vfsStreamStructureVisitor visit a directory and process it
visitFile ( org\bovigo\vfs\vfsStreamFile $file ) : vfsStreamStructureVisitor visit a file and process it

Method Details

__construct() public method

constructor
public __construct ( )

getStructure() public method

returns structure of visited contents
public getStructure ( ) : array
return array

reset() public method

resets structure so visitor could be reused
public reset ( ) : vfsStreamStructureVisitor
return vfsStreamStructureVisitor

visitBlockDevice() public method

visit a block device and process it
public visitBlockDevice ( org\bovigo\vfs\vfsStreamBlock $block ) : vfsStreamStructureVisitor
$block org\bovigo\vfs\vfsStreamBlock
return vfsStreamStructureVisitor

visitDirectory() public method

visit a directory and process it
public visitDirectory ( vfsStreamDirectory $dir ) : vfsStreamStructureVisitor
$dir org\bovigo\vfs\vfsStreamDirectory
return vfsStreamStructureVisitor

visitFile() public method

visit a file and process it
public visitFile ( org\bovigo\vfs\vfsStreamFile $file ) : vfsStreamStructureVisitor
$file org\bovigo\vfs\vfsStreamFile
return vfsStreamStructureVisitor

Property Details

$current protected property

poiting to currently iterated directory
protected $current

$structure protected property

collected structure
protected $structure