Lines Matching refs:tree
20 $tree = $this->_groupByNs($tab);
21 $trimmedTree = $this->_getTrimmedTree($tree);
30 function _orderTree($tree) { argument
42 $this->_sorter->sort($tree->children);
44 foreach($tree->children as $subTree){
49 return $tree;
53 $tree = new NspagesTreeNsNode(':');
55 $this->_fillTree($tree, $this->_getNS($item), $item, '', ':');
57 return $tree;
71 private function _getTrimmedTree($tree){ argument
72 if ($tree->id === $this->rootNS){
73 return $tree;
75 if (is_null($tree->children)) {
78 return $tree;
80 $firstAndOnlyChild = reset($tree->children);
140 private function _fillTree($tree, $keys, $item, $parentId, $myNs) { argument
143 $tree->self = $item;
146 $tree->self = $item;
148 if (!isset($tree->children[$item['id']])) {
150 $tree->children[$item['id']] = new NspagesTreeNsNode($item['id']);
151 $tree->children[$item['id']]->self = $item;
153 $tree->children[$item['id']] = $item;
156 $tree->children[$item['id']]->self = $item;
164 if (!array_key_exists($nsKey, $tree->children)){
166 $tree->children[$nsKey] = $node;
169 $this->_fillTree($tree->children[$nsKey], $keys, $item, $currentId, $item['ns']);
173 private function _printTree($tree) { argument
176 foreach($tree->children as $subTree){
187 private function _printSubTree($tree, $level) { argument
188 $this->_printElementOpen($tree->self, $level);
189 if ( !is_null($tree->self) ){
190 $this->_printElementContent($tree->self, $level);
192 $this->renderer->doc .= '<div>' . $tree->id . '</div>';
195 $hasInnerData = !empty($tree->children);
199 foreach($tree->children as $subTree){