vfsStreamDirectory.php

Show: inherited
Table of Contents

Directory container.

Package
bovigo_vfs  

\vfsStreamDirectory

Package: bovigo\vfs

Directory container.

Parent(s)
\vfsStreamAbstractContent < \vfsStreamContent

Properties

Propertyprotected\array<string,vfsStreamContent>  $children= 'array()'

list of directory children

Default valuearray()Details
Type
\array<string,vfsStreamContent>
Propertyprotectedint  $group= ''
inherited

owner group of the file

Inherited from: \vfsStreamAbstractContent::$$group
Details
Type
int
Inherited_from
\vfsStreamAbstractContent::$$group  
Propertyprotectedint  $lastAccessed= ''
inherited

timestamp of last access

Inherited from: \vfsStreamAbstractContent::$$lastAccessed
Details
Type
int
Inherited_from
\vfsStreamAbstractContent::$$lastAccessed  
Propertyprotectedint  $lastAttributeModified= ''
inherited

timestamp of last attribute modification

Inherited from: \vfsStreamAbstractContent::$$lastAttributeModified
Details
Type
int
Inherited_from
\vfsStreamAbstractContent::$$lastAttributeModified  
Propertyprotectedint  $lastModified= ''
inherited

timestamp of last modification

Inherited from: \vfsStreamAbstractContent::$$lastModified
Details
Type
int
Inherited_from
\vfsStreamAbstractContent::$$lastModified  
Propertyprotectedstring  $name= ''
inherited

name of the container

Inherited from: \vfsStreamAbstractContent::$$name
Details
Type
string
Inherited_from
\vfsStreamAbstractContent::$$name  
Propertyprotectedint  $permissions= ''
inherited

permissions for content

Inherited from: \vfsStreamAbstractContent::$$permissions
Details
Type
int
Inherited_from
\vfsStreamAbstractContent::$$permissions  
Propertyprotectedstring  $type= ''
inherited

type of the container

Inherited from: \vfsStreamAbstractContent::$$type
Details
Type
string
Inherited_from
\vfsStreamAbstractContent::$$type  
Propertyprotectedint  $user= ''
inherited

owner of the file

Inherited from: \vfsStreamAbstractContent::$$user
Details
Type
int
Inherited_from
\vfsStreamAbstractContent::$$user  

Methods

methodpublic__construct( string $name, int $permissions = null ) : void

constructor

Parameters
Name Type Description
$name string
$permissions int

optional

Throws
Exception Description
\vfsStreamException
methodpublicaddChild( \vfsStreamContent $child ) : void

adds child to the directory

Parameters
Name Type Description
$child \vfsStreamContent
methodpublicappliesTo( string $name ) : bool
inherited

checks whether the container can be applied to given name

Inherited from: \vfsStreamAbstractContent::appliesTo()
Parameters
Name Type Description
$name string
Returns
Type Description
bool
methodpublicat( \vfsStreamContainer $container ) : \vfsStreamContent
inherited

adds content to given container

Inherited from: \vfsStreamAbstractContent::at()
Parameters
Name Type Description
$container \vfsStreamContainer
Returns
Type Description
\vfsStreamContent
methodpublicchgrp( int $group ) : \vfsStreamContent
inherited

change owner group of file to given group

Inherited from: \vfsStreamAbstractContent::chgrp()
Parameters
Name Type Description
$group int
Returns
Type Description
\vfsStreamContent
methodpublicchmod( int $permissions ) : \vfsStreamContent
inherited

change file mode to given permissions

Inherited from: \vfsStreamAbstractContent::chmod()
Parameters
Name Type Description
$permissions int
Returns
Type Description
\vfsStreamContent
methodpublicchown( int $user ) : \vfsStreamContent
inherited

change owner of file to given user

Inherited from: \vfsStreamAbstractContent::chown()
Parameters
Name Type Description
$user int
Returns
Type Description
\vfsStreamContent
methodpublicfileatime( ) : int
inherited

returns the last access time of the stream content

Inherited from: \vfsStreamAbstractContent::fileatime()
Returns
Type Description
int
Details
Since
0.9  
methodpublicfilectime( ) : int
inherited

returns the last attribute modification time of the stream content

Inherited from: \vfsStreamAbstractContent::filectime()
Returns
Type Description
int
Details
Since
0.9  
methodpublicfilemtime( ) : int
inherited

returns the last modification time of the stream content

Inherited from: \vfsStreamAbstractContent::filemtime()
Returns
Type Description
int
methodpublicgetChild( string $name ) : \vfsStreamContent

returns the child with the given name

Parameters
Name Type Description
$name string
Returns
Type Description
\vfsStreamContent
methodprotectedgetChildName( string $name, string $ownName ) : string
static

helper method to calculate the child name

Parameters
Name Type Description
$name string
$ownName string
Returns
Type Description
string
methodpublicgetChildren( ) : \array<vfsStreamContent>

returns a list of children for this directory

Returns
Type Description
\array<vfsStreamContent>
methodprotectedgetDefaultPermissions( ) : int

returns default permissions for concrete implementation

Returns
Type Description
int
Details
Since
0.8.0  
methodpublicgetGroup( ) : int
inherited

returns owner group of file

Inherited from: \vfsStreamAbstractContent::getGroup()
Returns
Type Description
int
methodpublicgetIterator( ) : \vfsStreamContainerIterator

returns iterator for the children

Returns
Type Description
\vfsStreamContainerIterator
methodpublicgetName( ) : string
inherited

returns the file name of the content

Inherited from: \vfsStreamAbstractContent::getName()
Returns
Type Description
string
methodpublicgetPermissions( ) : int
inherited

returns permissions

Inherited from: \vfsStreamAbstractContent::getPermissions()
Returns
Type Description
int
methodprotectedgetRealChildName( string $name ) : string

helper method to detect the real child name

Parameters
Name Type Description
$name string
Returns
Type Description
string
methodpublicgetType( ) : int
inherited

returns the type of the container

Inherited from: \vfsStreamAbstractContent::getType()
Returns
Type Description
int
methodpublicgetUser( ) : int
inherited

returns owner of file

Inherited from: \vfsStreamAbstractContent::getUser()
Returns
Type Description
int
methodpublichasChild( string $name ) : bool

checks whether the container contains a child with the given name

Parameters
Name Type Description
$name string
Returns
Type Description
bool
methodpublichasChildren( ) : bool

checks whether directory contains any children

Returns
Type Description
bool
Details
Since
0.10.0  
methodpublicisExecutable( int $user, int $group ) : bool
inherited

checks whether content is executable

Inherited from: \vfsStreamAbstractContent::isExecutable()
Parameters
Name Type Description
$user int

id of user to check for

$group int

id of group to check for

Returns
Type Description
bool
methodpublicisOwnedByGroup( int $group ) : bool
inherited

checks whether file is owned by group

Inherited from: \vfsStreamAbstractContent::isOwnedByGroup()
Parameters
Name Type Description
$group int
Returns
Type Description
bool
methodpublicisOwnedByUser( int $user ) : bool
inherited

checks whether file is owned by given user

Inherited from: \vfsStreamAbstractContent::isOwnedByUser()
Parameters
Name Type Description
$user int
Returns
Type Description
bool
methodpublicisReadable( int $user, int $group ) : bool
inherited

checks whether content is readable

Inherited from: \vfsStreamAbstractContent::isReadable()
Parameters
Name Type Description
$user int

id of user to check for

$group int

id of group to check for

Returns
Type Description
bool
methodpublicisWritable( int $user, int $group ) : bool
inherited

checks whether content is writable

Inherited from: \vfsStreamAbstractContent::isWritable()
Parameters
Name Type Description
$user int

id of user to check for

$group int

id of group to check for

Returns
Type Description
bool
methodpubliclastAccessed( int $fileatime ) : \vfsStreamContent
inherited

sets last access time of the stream content

Inherited from: \vfsStreamAbstractContent::lastAccessed()
Parameters
Name Type Description
$fileatime int
Returns
Type Description
\vfsStreamContent
Details
Since
0.9  
methodpubliclastAttributeModified( int $filectime ) : \vfsStreamContent
inherited

sets the last attribute modification time of the stream content

Inherited from: \vfsStreamAbstractContent::lastAttributeModified()
Parameters
Name Type Description
$filectime int
Returns
Type Description
\vfsStreamContent
Details
Since
0.9  
methodpubliclastModified( int $filemtime ) : \vfsStreamContent
inherited

sets the last modification time of the stream content

Inherited from: \vfsStreamAbstractContent::lastModified()
Parameters
Name Type Description
$filemtime int
Returns
Type Description
\vfsStreamContent
methodpublicremoveChild( string $name ) : bool

removes child from the directory

Parameters
Name Type Description
$name string
Returns
Type Description
bool
methodpublicrename( string $newName ) : void

renames the content

Parameters
Name Type Description
$newName string
Throws
Exception Description
\vfsStreamException
methodpublicsize( ) : int

returns size of directory

The size of a directory is always 0 bytes. To calculate the summarized size of all children in the directory use sizeSummarized().

Returns
Type Description
int
methodpublicsizeSummarized( ) : int

returns summarized size of directory and its children

Returns
Type Description
int
methodprotectedupdateModifications( ) : void

updates internal timestamps

Documentation was generated by DocBlox 0.18.1.