ILIAS  Release_4_4_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
class.ilLMTree.php
Go to the documentation of this file.
1 <?php
2 
3 /* Copyright (c) 1998-2014 ILIAS open source, Extended GPL, see docs/LICENSE */
4 
12 class ilLMTree extends ilTree
13 {
14  static $instances = array();
15 
21  private function __construct($a_tree_id)
22  {
23  parent::ilTree($a_tree_id);
24  $this->setTableNames('lm_tree','lm_data');
25  $this->setTreeTablePK("lm_id");
26  $this->useCache(true);
27  }
28 
35  static function getInstance($a_tree_id)
36  {
37  if (isset(self::$instances[$a_tree_id]))
38  {
39  return self::$instances[$a_tree_id];
40  }
41  $tree = new ilLMTree($a_tree_id);
42  self::$instances[$a_tree_id] = $tree;
43 
44  return $tree;
45  }
46 
47 
52  public function isCacheUsed()
53  {
54  return $this->use_cache;
55  }
56 
57 
58 }
59 
60 ?>