Documentation

TreeDirectoryTester extends SimpleCollection
in package

SimpleCollection.

The SimpleCollection is used to quickly setup static directory structures. Just create the object with a proper name, and add children to use it.

Table of Contents

$isDeleted  : mixed
$isRenamed  : mixed
$newDirectories  : mixed
$newFiles  : mixed
$children  : array<string|int, INode>
List of childnodes.
$name  : string
Name of this resource.
__construct()  : mixed
Creates this node.
addChild()  : mixed
Adds a new childnode to this collection.
childExists()  : mixed
createDirectory()  : mixed
createFile()  : mixed
delete()  : mixed
getChild()  : INode
Returns a child object, by its name.
getChildren()  : array<string|int, INode>
Returns a list of children for this collection.
getLastModified()  : int
Returns the last modification time as a unix timestamp.
getName()  : string
Returns the name of the collection.
setName()  : mixed

Properties

$isDeleted

public mixed $isDeleted = false

$isRenamed

public mixed $isRenamed = false

$newDirectories

public mixed $newDirectories = []

Methods

__construct()

Creates this node.

public __construct(string $name[, array<string|int, INode$children = [] ]) : mixed

The name of the node must be passed, child nodes can also be passed. This nodes must be instances of INode

Parameters
$name : string
$children : array<string|int, INode> = []
Return values
mixed

addChild()

Adds a new childnode to this collection.

public addChild(INode $child) : mixed
Parameters
$child : INode
Return values
mixed

childExists()

public childExists(mixed $name) : mixed
Parameters
$name : mixed
Return values
mixed

createDirectory()

public createDirectory(mixed $name) : mixed
Parameters
$name : mixed
Return values
mixed

createFile()

public createFile(mixed $name[, mixed $data = null ]) : mixed
Parameters
$name : mixed
$data : mixed = null
Return values
mixed

delete()

public delete() : mixed
Return values
mixed

getChild()

Returns a child object, by its name.

public getChild(mixed $name) : INode

This method makes use of the getChildren method to grab all the child nodes, and compares the name. Generally its wise to override this, as this can usually be optimized

This method must throw Sabre\DAV\Exception\NotFound if the node does not exist.

Parameters
$name : mixed
Return values
INode

getChildren()

Returns a list of children for this collection.

public getChildren() : array<string|int, INode>
Return values
array<string|int, INode>

getLastModified()

Returns the last modification time as a unix timestamp.

public getLastModified() : int

If the information is not available, return null.

Return values
int

getName()

Returns the name of the collection.

public getName() : string
Return values
string

setName()

public setName(mixed $name) : mixed
Parameters
$name : mixed
Return values
mixed

Search results