ILIAS
release_5-3 Revision v5.3.23-19-g915713cf615
|
Base class for materialize path based trees Based on implementation of Werner Randelshofer. More...
Public Member Functions | |
__construct (ilTree $a_tree) | |
Constructor. More... | |
getTree () | |
Get tree object. More... | |
getSubTreeIds ($a_node_id) | |
Get subtree ids. More... | |
getRelation ($a_node_a, $a_node_b) | |
Get relation of two nodes. More... | |
getSubTreeQuery ($a_node, $a_types='', $a_force_join_reference=true, $a_fields=array()) | |
Get subtree query. More... | |
getPathIds ($a_endnode, $a_startnode=0) | |
Get path ids. More... | |
insertNode ($a_node_id, $a_parent_id, $a_pos) | |
Insert new node under parent node. More... | |
deleteTree ($a_node_id) | |
Delete a subtree. More... | |
moveToTrash ($a_node_id) | |
Move subtree to trash. More... | |
moveTree ($a_source_id, $a_target_id, $a_position) | |
move source subtree to target node More... | |
getSubtreeInfo ($a_endnode_id) | |
validateParentRelations () | |
Validaate parent relations. More... | |
Static Public Member Functions | |
static | createFromParentReleation () |
Protected Member Functions | |
getMaximumPossibleDepth () | |
Get maximum possible depth. More... | |
Static Private Member Functions | |
static | createMaterializedPath ($parent, $parentPath) |
Private Attributes | |
$maximum_possible_depth = 100 | |
$tree = null | |
Base class for materialize path based trees Based on implementation of Werner Randelshofer.
Definition at line 16 of file class.ilMaterializedPathTree.php.
ilMaterializedPathTree::__construct | ( | ilTree | $a_tree | ) |
Constructor.
ilTree | $a_tree |
Definition at line 25 of file class.ilMaterializedPathTree.php.
|
static |
Definition at line 441 of file class.ilMaterializedPathTree.php.
References $ilDB, $r, $row, $success, and array.
Referenced by ilSCTreeTasksGUI\repairStructure(), and ilSetupGUI\switchTree().
|
staticprivate |
type | $parent | |
type | $parentPath |
Definition at line 460 of file class.ilMaterializedPathTree.php.
ilMaterializedPathTree::deleteTree | ( | $a_node_id | ) |
Delete a subtree.
int | $a_node_id |
Implements ilTreeImplementation.
Definition at line 262 of file class.ilMaterializedPathTree.php.
References $ilDB, $query, $res, $row, array, and getTree().
|
protected |
Get maximum possible depth.
Definition at line 35 of file class.ilMaterializedPathTree.php.
References $maximum_possible_depth.
ilMaterializedPathTree::getPathIds | ( | $a_endnode, | |
$a_startnode = 0 |
|||
) |
Get path ids.
int | $a_endnode | |
int | $a_startnode |
Implements ilTreeImplementation.
Definition at line 165 of file class.ilMaterializedPathTree.php.
References $ilDB, $path, $query, $res, $row, and getTree().
ilMaterializedPathTree::getRelation | ( | $a_node_a, | |
$a_node_b | |||
) |
Get relation of two nodes.
type | $a_node_a | |
type | $a_node_b |
Implements ilTreeImplementation.
Definition at line 83 of file class.ilMaterializedPathTree.php.
References ilLoggerFactory\getLogger(), ilTree\RELATION_CHILD, ilTree\RELATION_EQUALS, ilTree\RELATION_NONE, ilTree\RELATION_PARENT, and ilTree\RELATION_SIBLING.
ilMaterializedPathTree::getSubTreeIds | ( | $a_node_id | ) |
Get subtree ids.
type | $a_node_id |
Implements ilTreeImplementation.
Definition at line 54 of file class.ilMaterializedPathTree.php.
References $ilDB, $query, $res, $row, array, and getTree().
ilMaterializedPathTree::getSubtreeInfo | ( | $a_endnode_id | ) |
int | $a_endnode_id |
Implements ilTreeImplementation.
Definition at line 481 of file class.ilMaterializedPathTree.php.
References $ilDB, $query, $res, $row, array, ilDBConstants\FETCHMODE_OBJECT, and getTree().
ilMaterializedPathTree::getSubTreeQuery | ( | $a_node, | |
$a_types = '' , |
|||
$a_force_join_reference = true , |
|||
$a_fields = array() |
|||
) |
Get subtree query.
type | $a_node | |
string | $a_types | |
bool | $a_force_join_reference | |
array | $a_fields |
Implements ilTreeImplementation.
Definition at line 120 of file class.ilMaterializedPathTree.php.
References $ilDB, $query, and getTree().
ilMaterializedPathTree::getTree | ( | ) |
Get tree object.
Definition at line 44 of file class.ilMaterializedPathTree.php.
References $tree.
Referenced by deleteTree(), getPathIds(), getSubTreeIds(), getSubtreeInfo(), getSubTreeQuery(), insertNode(), moveToTrash(), moveTree(), and validateParentRelations().
ilMaterializedPathTree::insertNode | ( | $a_node_id, | |
$a_parent_id, | |||
$a_pos | |||
) |
Insert new node under parent node.
int | $a_node_id | |
int | $a_parent_id | |
int | $a_pos |
ilInvalidTreeStructureException |
Implements ilTreeImplementation.
Definition at line 197 of file class.ilMaterializedPathTree.php.
References $ilDB, $r, $res, array, ilLogLevel\ERROR, ilLoggerFactory\getLogger(), and getTree().
ilMaterializedPathTree::moveToTrash | ( | $a_node_id | ) |
Move subtree to trash.
type | $a_node_id |
Implements ilTreeImplementation.
Definition at line 300 of file class.ilMaterializedPathTree.php.
References $ilDB, array, and getTree().
ilMaterializedPathTree::moveTree | ( | $a_source_id, | |
$a_target_id, | |||
$a_position | |||
) |
move source subtree to target node
int | $a_source_id | |
int | $a_target_id | |
int | $a_position |
InvalidArgumentException |
Implements ilTreeImplementation.
Definition at line 344 of file class.ilMaterializedPathTree.php.
References $ilDB, $query, $res, $row, array, ilLogLevel\ERROR, ilLoggerFactory\getLogger(), and getTree().
ilMaterializedPathTree::validateParentRelations | ( | ) |
Validaate parent relations.
Implements ilTreeImplementation.
Definition at line 541 of file class.ilMaterializedPathTree.php.
References $ilDB, $query, $res, $row, array, ilDBConstants\FETCHMODE_ASSOC, ilLoggerFactory\getLogger(), and getTree().
|
private |
Definition at line 18 of file class.ilMaterializedPathTree.php.
Referenced by getMaximumPossibleDepth().
|
private |
Definition at line 19 of file class.ilMaterializedPathTree.php.
Referenced by getTree().