_flattenArray()
addItem()
addItemToID()
cTreeItem()
collapseBelowID()
collapseBelowLevel()
deleteAttribute()
deleteItem()
expandBelowID()
expandBelowLevel()
exportTree()
flatTraverse()
getAttribute()
getCollapsedList()
getExpandedList()
getItemByID()
hasAttribute()
importStructuredArray()
importTable()
moveItem()
setAttribute()
setAttributes()
setCollapsed()
setExpanded()
setName()
setPayloadObject()
traverse()
unsetPayloadObject()
$_attributes
$_collapsed
$_id
$_level
$_name
$_next
$_parent
$_previous
$_subitems
class cTreeItem
_flattenArray($sourcearray, $destarray, $lastid, $level)
cTreeItem($id, $name, $collapsed)
collapseBelowID(int $id, $found) : void
| access | public |
|---|
intleveloffset Level offset. Ignores all expand operations below the offset.
collapseBelowLevel(int $leveloffset) : void
| access | public |
|---|
intleveloffset Level offset. Ignores all expand operations below the offset.
deleteAttribute(string $attributeName) : void
| access | public |
|---|
stringattributeName
deleteItem(mixed $id) : \deleted
| access | public |
|---|
mixeditem object or ID to delete
\deletedobjectexportTree() : array
| access | public |
|---|
arrayflatTraverse(integer $level)
integerLevel to start on
getAttribute(string $attributeName) : mixed
| access | public |
|---|
stringattributeName
mixedgetCollapsedList(array $list)
arrayContains the list with all collapsed items
getExpandedList(array $list)
arrayContains the list with all expanded items
getItemByID(string $id) : \cTreeItem
hasAttribute($attributeName, $bRecursive)
importStructuredArray($array)
importTable(array $flat_array) : void
The entries "collapsed" and "attributes" are optional!
| access | public |
|---|
arrayflat_array See above
moveItem(\cTreeItem $targetItem, mixed $itemToMove) : void
| access | public |
|---|
mixeditemToMove cTreeItem-Object or id of object to move
setAttribute(string $attributeName, array $attributeValue) : void
| access | public |
|---|
stringattributeName
arrayattributeValue The value(s) of the attribute
setAttributes(string $aAttributeArray) : void
| access | public |
|---|
stringattributeName
setCollapsed(mixed $id) : void
| access | public |
|---|
mixedcollapse ID to collapse or an array with items to collapse
setExpanded(mixed $id) : void
| access | public |
|---|
mixedexpand ID of item to expand or array of item ID's to expand
setName(string $name) : \none
stringNew name for this item
\nonesetPayloadObject(object $payload) : void
| access | public |
|---|
objectpayload The object to payload
traverse(object $objects, integer $level)
objectall found objects
integerLevel to start on
unsetPayloadObject() : object
| access | public |
|---|
object$_attributes : array
$_collapsed : boolean
$_id : string
$_level : integer
$_name : string
$_next : array
$_parent : array
$_previous : array
$_subitems : array