TYPO3 CMS  TYPO3_6-2
TYPO3\CMS\Backend\Tree\TreeNodeCollection Class Reference
Inheritance diagram for TYPO3\CMS\Backend\Tree\TreeNodeCollection:
t3lib_tree_NodeCollection TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNodeCollection TYPO3\CMS\Backend\Tree\SortedTreeNodeCollection t3lib_tree_pagetree_NodeCollection t3lib_tree_SortedNodeCollection

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

This file is part of the TYPO3 CMS project.

It is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, either version 2 of the License, or any later version.

For the full copyright and license information, please read the LICENSE.txt file that was distributed with this source code.

The TYPO3 project - inspiring people to share! Tree Node Collection

Author
Stefan Galinski stefa.nosp@m.n.ga.nosp@m.linsk.nosp@m.i@gm.nosp@m.ail.c.nosp@m.om
Steffen Ritter info@.nosp@m.stef.nosp@m.fen-r.nosp@m.itte.nosp@m.r.net

Definition at line 22 of file TreeNodeCollection.php.

Constructor & Destructor Documentation

◆ __construct()

TYPO3\CMS\Backend\Tree\TreeNodeCollection::__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 32 of file TreeNodeCollection.php.

References TYPO3\CMS\Backend\Tree\TreeNodeCollection\dataFromArray().

Member Function Documentation

◆ asort()

TYPO3\CMS\Backend\Tree\TreeNodeCollection::asort ( )

Sorts the internal nodes array

Returns
void

Definition at line 43 of file TreeNodeCollection.php.

Referenced by TYPO3\CMS\Backend\Tree\SortedTreeNodeCollection\append().

◆ dataFromArray()

TYPO3\CMS\Backend\Tree\TreeNodeCollection::dataFromArray (   $data)

Sets the data of the node collection by a given array

Parameters
array$data
Returns
void

Definition at line 105 of file TreeNodeCollection.php.

References TYPO3\CMS\Core\Utility\GeneralUtility\makeInstance().

Referenced by TYPO3\CMS\Backend\Tree\TreeNodeCollection\__construct(), and TYPO3\CMS\Backend\Tree\TreeNodeCollection\unserialize().

◆ nodeCompare()

TYPO3\CMS\Backend\Tree\TreeNodeCollection::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()

TYPO3\CMS\Backend\Tree\TreeNodeCollection::serialize ( )

Returns the serialized instance

Returns
string

Definition at line 63 of file TreeNodeCollection.php.

References TYPO3\CMS\Backend\Tree\TreeNodeCollection\toArray().

◆ toArray()

TYPO3\CMS\Backend\Tree\TreeNodeCollection::toArray ( )

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

Returns
array

Definition at line 87 of file TreeNodeCollection.php.

Referenced by TYPO3\CMS\Backend\Tree\TreeNodeCollection\serialize().

◆ unserialize()

TYPO3\CMS\Backend\Tree\TreeNodeCollection::unserialize (   $serializedString)

Initializes the current object with a serialized instance

Parameters
string$serializedString
Returns
void
Exceptions

Definition at line 74 of file TreeNodeCollection.php.

References TYPO3\CMS\Backend\Tree\TreeNodeCollection\dataFromArray().