Exemplo n.º 1
0
 /**
  * Creates a flat list node items.
  *
  * @param MW_Tree_Node_Interface $node Root node
  * @return Associated list of ID / node object pairs
  */
 protected function _getNodeMap(MW_Tree_Node_Interface $node)
 {
     $map = array();
     $map[(string) $node->getId()] = $node;
     foreach ($node->getChildren() as $child) {
         $map += $this->_getNodeMap($child);
     }
     return $map;
 }