Пример #1
0
 /**
  * {@inheritdoc}
  */
 public function getItemTypes()
 {
     // Only entity types are exposed as their own item type, all others are
     // grouped together in simple config.
     $entity_types = $this->entityManager->getDefinitions();
     $definitions = $this->configMapperManager->getDefinitions();
     $types = array();
     foreach ($definitions as $definition_name => $definition) {
         if (isset($definition['entity_type'])) {
             $types[$definition['entity_type']] = (string) $entity_types[$definition['entity_type']]->getLabel();
         }
     }
     $types[static::SIMPLE_CONFIG] = t('Simple configuration');
     return $types;
 }