33         $this->
setTableNames(
'tree_workspace', 
'object_data', 
'object_reference_ws');
    52             "SELECT * FROM tree_workspace " .
    72         $next_id = 
$ilDB->nextId($this->table_obj_reference);
    74         $fields = array($this->ref_pk => array(
"integer", $next_id),
    75             $this->obj_pk => array(
"integer", $a_object_id));
    77         $ilDB->insert($this->table_obj_reference, $fields);
    91         $set = 
$ilDB->query(
"SELECT " . $this->obj_pk .
    92             " FROM " . $this->table_obj_reference .
    93             " WHERE " . $this->ref_pk . 
" = " . 
$ilDB->quote($a_node_id, 
"integer"));
   110         $set = 
$ilDB->query(
"SELECT " . $this->ref_pk .
   111             " FROM " . $this->table_obj_reference .
   112             " WHERE " . $this->obj_pk . 
" = " . 
$ilDB->quote($a_obj_id, 
"integer"));
   127         $set = 
$ilDB->query(
"SELECT tree" .
   128             " FROM " . $this->table_obj_reference .
   129             " JOIN " . $this->table_tree . 
" ON (" . $this->table_obj_reference . 
"." . $this->ref_pk . 
" = " . $this->table_tree . 
".child)" .
   130             " WHERE " . $this->ref_pk . 
" = " . 
$ilDB->quote($a_node_id, 
"integer"));
   133         return (
int) (
$res[
"tree"] ?? 0);
   144         int $a_parent_node_id,
   148         $this->
insertNode($node_id, $a_parent_node_id);
   159         $query = 
"DELETE FROM " . $this->table_obj_reference .
   160             " WHERE " . $this->ref_pk . 
" = " . 
$ilDB->quote($a_node_id, 
"integer");
   161         return $ilDB->manipulate($query);
   180         foreach ($nodes as $node) {
   181             $access_handler->removePermission($node[
"wsp_id"]);
   200         bool $a_with_data = 
false   216         $root = 
new $root(0);
 
setObjectTablePK(string $a_column_name)
set column containing primary key in object table 
 
getNodeData(int $a_node_id, ?int $a_tree_pk=null)
get all information of a node. 
 
fetchAssoc(ilDBStatement $statement)
 
getObjectsFromType(string $a_type, bool $a_with_data=false)
Get all workspace objects of specific type. 
 
cascadingDelete()
Remove all tree and node data. 
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
setTreeTablePK(string $a_column_name)
set column containing primary key in tree table 
 
deleteTree(array $a_node)
delete node and the whole subtree under this node 
 
addTree(int $a_tree_id, int $a_node_id=-1)
create a new tree to do: ??? 
 
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
 
__construct(int $a_tree_id, int $a_root_id=0)
 
setTableNames(string $a_table_tree, string $a_table_obj_data, string $a_table_obj_reference="")
set table names The primary key of the table containing your object_data must be 'obj_id' You may use...
 
int $root_id
points to root node (may be a subtree) 
 
deleteReference(int $a_node_id)
Delete object from reference table. 
 
setRootId(int $a_root_id)
 
queryF(string $query, array $types, array $values)
 
static getClassByType(string $obj_type)
 
static getInstanceByObjId(?int $obj_id, bool $stop_on_error=true)
get an instance of an Ilias object by object id 
 
lookupObjectId(int $a_node_id)
Get object id for node id. 
 
lookupOwner(int $a_node_id)
Get owner for node id. 
 
insertNode(int $a_node_id, int $a_parent_id, int $a_pos=self::POS_LAST_NODE, bool $a_reset_deletion_date=false)
insert new node with node_id under parent node with parent_id 
 
string $obj_pk
column name containing primary key in object table 
 
string $ref_pk
column name containing primary key in reference table 
 
createTreeForUser(int $a_user_id)
Create personal workspace tree for user. 
 
getSubTree(array $a_node, bool $a_with_data=true, array $a_type=[])
get all nodes in the subtree under specified node 
 
createReference(int $a_object_id)
Create workspace reference for object. 
 
insertObject(int $a_parent_node_id, int $a_object_id)
Add object to tree. 
 
setReferenceTablePK(string $a_column_name)
set column containing primary key in reference table 
 
lookupNodeId(int $a_obj_id)
Get node id for object id As we do not allow references in workspace this should not be ambigious...