TYPO3  7.6
Public Member Functions | List of all members
TreeNodeCollection Class Reference
Inheritance diagram for TreeNodeCollection:
PagetreeNodeCollection SortedTreeNodeCollection

Public Member Functions

 __construct (array $data=array())
 
 asort ()
 
 nodeCompare (\TYPO3\CMS\Backend\Tree\TreeNode $node,\TYPO3\CMS\Backend\Tree\TreeNode $otherNode)
 
 serialize ()
 
 unserialize ($serializedString)
 
 toArray ()
 
 dataFromArray ($data)
 

Detailed Description

Tree Node Collection

Definition at line 20 of file TreeNodeCollection.php.

Constructor & Destructor Documentation

__construct ( array  $data = array())

Constructor

You can move an initial data array to initialize the instance and further objects. This is useful for the deserialization.

Parameters
array$data

Definition at line 30 of file TreeNodeCollection.php.

References TreeNodeCollection\dataFromArray().

Member Function Documentation

asort ( )

Sorts the internal nodes array

Returns
void

Definition at line 42 of file TreeNodeCollection.php.

Referenced by SortedTreeNodeCollection\append().

dataFromArray (   $data)

Sets the data of the node collection by a given array

Parameters
array$data
Returns
void

Definition at line 109 of file TreeNodeCollection.php.

Referenced by TreeNodeCollection\__construct(), and TreeNodeCollection\unserialize().

nodeCompare ( \TYPO3\CMS\Backend\Tree\TreeNode  $node,
\TYPO3\CMS\Backend\Tree\TreeNode  $otherNode 
)

Compares a node with another one

See Also
::compareTo
Returns
void

Definition at line 54 of file TreeNodeCollection.php.

serialize ( )

Returns the serialized instance

Returns
string

Definition at line 64 of file TreeNodeCollection.php.

References TreeNodeCollection\toArray().

toArray ( )

Returns the collection in an array representation for e.g. serialization

Returns
array

Definition at line 90 of file TreeNodeCollection.php.

Referenced by TreeNodeCollection\serialize().

unserialize (   $serializedString)

Initializes the current object with a serialized instance

Parameters
string$serializedString
Returns
void
Exceptions
\TYPO3\CMS\Core\Exceptionif the deserialized is not identical to the current class

Definition at line 76 of file TreeNodeCollection.php.

References TreeNodeCollection\dataFromArray().