ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilTreeImplementation Interface Reference

Interface for tree implementations Currrently nested set or materialize path. More...

+ Inheritance diagram for ilTreeImplementation:
+ Collaboration diagram for ilTreeImplementation:

Public Member Functions

 getSubTreeIds ($a_node_id)
 Get subtree ids for a specific node. More...
 
 getSubTreeQuery ($a_node, $a_types='', $a_force_join_reference=true, $a_fields=array())
 Get subtree. More...
 
 getRelation ($a_node_a, $a_node_b)
 Get relation of two nodes. More...
 
 getPathIds ($a_endnode, $a_startnode=0)
 Get path ids from a startnode to a given endnode. More...
 
 insertNode ($a_node_id, $a_parent_id, $a_pos)
 
 deleteTree ($a_node_id)
 Delete tree. More...
 
 moveToTrash ($a_node_id)
 Move subtree to trash. More...
 
 moveTree ($a_source_id, $a_target_id, $a_position)
 Move a source subtree to target. More...
 
 getSubtreeInfo ($a_endnode_id)
 Get subtree info lft, rgt, path, child, type. More...
 
 validateParentRelations ()
 Validate the parent relations of the tree implementation For nested set, validate the lft, rgt against child <-> parent For materialized path validate path against child <-> parent. More...
 

Detailed Description

Interface for tree implementations Currrently nested set or materialize path.

Author
Stefan Meyer smeye.nosp@m.r.il.nosp@m.ias@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

Definition at line 14 of file interface.ilTreeImplementation.php.

Member Function Documentation

◆ deleteTree()

ilTreeImplementation::deleteTree (   $a_node_id)

Delete tree.

Parameters
int$node_id

Implemented in ilNestedSetTree, and ilMaterializedPathTree.

◆ getPathIds()

ilTreeImplementation::getPathIds (   $a_endnode,
  $a_startnode = 0 
)

Get path ids from a startnode to a given endnode.

Parameters
int$a_endnode
int$a_startnode

Implemented in ilMaterializedPathTree, and ilNestedSetTree.

◆ getRelation()

ilTreeImplementation::getRelation (   $a_node_a,
  $a_node_b 
)

Get relation of two nodes.

See also
ilTree RELATION_NONE, RELATION_CHILD, RELATION_PARENT, RELATION_SIBLING
Parameters
array$a_node_a
array$a_node_b
Returns
int relation

Implemented in ilNestedSetTree, and ilMaterializedPathTree.

◆ getSubTreeIds()

ilTreeImplementation::getSubTreeIds (   $a_node_id)

Get subtree ids for a specific node.

Returns
array node_ids
Todo:
should be merged with getSubTree()

Implemented in ilMaterializedPathTree, and ilNestedSetTree.

◆ getSubtreeInfo()

ilTreeImplementation::getSubtreeInfo (   $a_endnode_id)

Get subtree info lft, rgt, path, child, type.

Returns
array

Implemented in ilNestedSetTree, and ilMaterializedPathTree.

◆ getSubTreeQuery()

ilTreeImplementation::getSubTreeQuery (   $a_node,
  $a_types = '',
  $a_force_join_reference = true,
  $a_fields = array() 
)

Get subtree.

Parameters
array$a_node
mixed$a_types

Implemented in ilMaterializedPathTree, and ilNestedSetTree.

◆ insertNode()

ilTreeImplementation::insertNode (   $a_node_id,
  $a_parent_id,
  $a_pos 
)

◆ moveToTrash()

ilTreeImplementation::moveToTrash (   $a_node_id)

Move subtree to trash.

Parameters
type$a_node_id

Implemented in ilNestedSetTree, and ilMaterializedPathTree.

◆ moveTree()

ilTreeImplementation::moveTree (   $a_source_id,
  $a_target_id,
  $a_position 
)

Move a source subtree to target.

Parameters
type$a_source_id
type$a_target_id
type$a_position

Implemented in ilNestedSetTree, and ilMaterializedPathTree.

◆ validateParentRelations()

ilTreeImplementation::validateParentRelations ( )

Validate the parent relations of the tree implementation For nested set, validate the lft, rgt against child <-> parent For materialized path validate path against child <-> parent.

Returns
int[] array of failure nodes

Implemented in ilNestedSetTree, and ilMaterializedPathTree.


The documentation for this interface was generated from the following file: