コード例 #1
0
 /**
  * @return array
  */
 public function getAllContentTypeClasses()
 {
     if (null === $this->allTypes) {
         $homePages = array_keys($this->pagesConfiguration->getHomepageTypes());
         $this->allTypes = array_unique(array_reduce($homePages, function ($allTypes, $homePage) {
             return array_merge($allTypes, iterator_to_array($this->getTypesDeep($homePage)));
         }, $homePages));
         $this->allTypes = array_combine(array_map([$this, 'getFriendlyName'], $this->allTypes), $this->allTypes);
     }
     return $this->allTypes;
 }
コード例 #2
0
 /**
  * @return array
  */
 public function getHomepageTypes()
 {
     return $this->pagesConfiguration->getHomepageTypes();
 }