14 private static $categoriesList = array();
15 private static $indices = array(
16 'parent_keys' => array(),
24 return Common::EVENT_CATEGORY_COLLECT;
30 public function call()
32 if (empty(self::$categoriesList))
36 foreach ($categories as $key => $category)
38 self::$categoriesList[$category->getKey()] = $category;
39 $parentKey = $category->getParentKey() ?:
'HEAD';
40 self::$indices[
'parent_keys'][$parentKey][] = $category->getKey();
44 return self::$categoriesList;
52 return self::$categoriesList;
60 return self::$indices;