getAvailableConfigurationTypes() public method

Get the available configuration-types
public getAvailableConfigurationTypes ( ) : array
return array
 /**
  * @param string $type
  * @return void
  */
 public function indexAction($type = 'Settings')
 {
     $availableConfigurationTypes = $this->configurationManager->getAvailableConfigurationTypes();
     $this->view->assignMultiple(array('type' => $type, 'availableConfigurationTypes' => $availableConfigurationTypes));
     if (in_array($type, $availableConfigurationTypes)) {
         $this->view->assign('configuration', $this->configurationManager->getConfiguration($type));
         try {
             $this->view->assign('validationResult', $this->configurationSchemaValidator->validate($type));
         } catch (SchemaValidationException $exception) {
             $this->addFlashMessage(htmlspecialchars($exception->getMessage()), 'An error occurred during validation of the configuration.', Message::SEVERITY_ERROR, array(), 1412373972);
         }
     } else {
         $this->addFlashMessage('Configuration type not found.', '', Message::SEVERITY_ERROR, array(), 1412373998);
     }
 }
 /**
  * List registered configuration types
  *
  * @return void
  */
 public function listTypesCommand()
 {
     $this->outputLine('The following configuration types are registered:');
     $this->outputLine();
     foreach ($this->configurationManager->getAvailableConfigurationTypes() as $type) {
         $this->outputFormatted('- %s', [$type]);
     }
 }
 /**
  * Validate a single configuration type
  *
  * @param string $configurationType the configuration typr to validate
  * @param string $path configuration path to validate, or NULL.
  * @param array $loadedSchemaFiles will be filled with a list of loaded schema files
  * @return \Neos\Error\Messages\Result
  * @throws Exception\SchemaValidationException
  */
 protected function validateSingleType($configurationType, $path, &$loadedSchemaFiles)
 {
     $availableConfigurationTypes = $this->configurationManager->getAvailableConfigurationTypes();
     if (in_array($configurationType, $availableConfigurationTypes) === false) {
         throw new Exception\SchemaValidationException('The configuration type "' . $configurationType . '" was not found. Only the following configuration types are supported: "' . implode('", "', $availableConfigurationTypes) . '"', 1364984886);
     }
     $configuration = $this->configurationManager->getConfiguration($configurationType);
     // find schema files for the given type and path
     $schemaFileInfos = [];
     $activePackages = $this->packageManager->getActivePackages();
     foreach ($activePackages as $package) {
         $packageKey = $package->getPackageKey();
         $packageSchemaPath = Files::concatenatePaths([$package->getResourcesPath(), 'Private/Schema']);
         if (is_dir($packageSchemaPath)) {
             foreach (Files::getRecursiveDirectoryGenerator($packageSchemaPath, '.schema.yaml') as $schemaFile) {
                 $schemaName = substr($schemaFile, strlen($packageSchemaPath) + 1, -strlen('.schema.yaml'));
                 $schemaNameParts = explode('.', str_replace('/', '.', $schemaName), 2);
                 $schemaType = $schemaNameParts[0];
                 $schemaPath = isset($schemaNameParts[1]) ? $schemaNameParts[1] : null;
                 if ($schemaType === $configurationType && ($path === null || strpos($schemaPath, $path) === 0)) {
                     $schemaFileInfos[] = ['file' => $schemaFile, 'name' => $schemaName, 'path' => $schemaPath, 'packageKey' => $packageKey];
                 }
             }
         }
     }
     if (count($schemaFileInfos) === 0) {
         throw new Exception\SchemaValidationException('No schema files found for configuration type "' . $configurationType . '"' . ($path !== null ? ' and path "' . $path . '".' : '.'), 1364985056);
     }
     $result = new Result();
     foreach ($schemaFileInfos as $schemaFileInfo) {
         $loadedSchemaFiles[] = $schemaFileInfo['file'];
         if ($schemaFileInfo['path'] !== null) {
             $data = Arrays::getValueByPath($configuration, $schemaFileInfo['path']);
         } else {
             $data = $configuration;
         }
         if (empty($data)) {
             $result->addNotice(new Notice('No configuration found, skipping schema "%s".', 1364985445, [substr($schemaFileInfo['file'], strlen(FLOW_PATH_ROOT))]));
         } else {
             $parsedSchema = Yaml::parse($schemaFileInfo['file']);
             $validationResultForSingleSchema = $this->schemaValidator->validate($data, $parsedSchema);
             if ($schemaFileInfo['path'] !== null) {
                 $result->forProperty($schemaFileInfo['path'])->merge($validationResultForSingleSchema);
             } else {
                 $result->merge($validationResultForSingleSchema);
             }
         }
     }
     return $result;
 }
 /**
  * Builds the code necessary to inject setter based dependencies.
  *
  * @param Configuration $objectConfiguration (needed to produce helpful exception message)
  * @return string The built code
  * @throws ObjectException\UnknownObjectException
  */
 protected function buildPropertyInjectionCode(Configuration $objectConfiguration)
 {
     $commands = [];
     $injectedProperties = [];
     foreach ($objectConfiguration->getProperties() as $propertyName => $propertyConfiguration) {
         /* @var $propertyConfiguration ConfigurationProperty */
         if ($propertyConfiguration->getAutowiring() === Configuration::AUTOWIRING_MODE_OFF) {
             continue;
         }
         $propertyValue = $propertyConfiguration->getValue();
         switch ($propertyConfiguration->getType()) {
             case ConfigurationProperty::PROPERTY_TYPES_OBJECT:
                 if ($propertyValue instanceof Configuration) {
                     $commands = array_merge($commands, $this->buildPropertyInjectionCodeByConfiguration($objectConfiguration, $propertyName, $propertyValue));
                 } else {
                     $commands = array_merge($commands, $this->buildPropertyInjectionCodeByString($objectConfiguration, $propertyConfiguration, $propertyName, $propertyValue));
                 }
                 break;
             case ConfigurationProperty::PROPERTY_TYPES_STRAIGHTVALUE:
                 if (is_string($propertyValue)) {
                     $preparedSetterArgument = '\'' . str_replace('\'', '\\\'', $propertyValue) . '\'';
                 } elseif (is_array($propertyValue)) {
                     $preparedSetterArgument = var_export($propertyValue, true);
                 } elseif (is_bool($propertyValue)) {
                     $preparedSetterArgument = $propertyValue ? 'TRUE' : 'FALSE';
                 } else {
                     $preparedSetterArgument = $propertyValue;
                 }
                 $commands[] = 'if (\\Neos\\Utility\\ObjectAccess::setProperty($this, \'' . $propertyName . '\', ' . $preparedSetterArgument . ') === FALSE) { $this->' . $propertyName . ' = ' . $preparedSetterArgument . ';}';
                 break;
             case ConfigurationProperty::PROPERTY_TYPES_CONFIGURATION:
                 $configurationType = $propertyValue['type'];
                 if (!in_array($configurationType, $this->configurationManager->getAvailableConfigurationTypes())) {
                     throw new ObjectException\UnknownObjectException('The configuration injection specified for property "' . $propertyName . '" in the object configuration of object "' . $objectConfiguration->getObjectName() . '" refers to the unknown configuration type "' . $configurationType . '".', 1420736211);
                 }
                 $commands = array_merge($commands, $this->buildPropertyInjectionCodeByConfigurationTypeAndPath($objectConfiguration, $propertyName, $configurationType, $propertyValue['path']));
                 break;
         }
         $injectedProperties[] = $propertyName;
     }
     if (count($commands) > 0) {
         $commandString = "    " . implode("\n    ", $commands) . "\n";
         $commandString .= '        $this->Flow_Injected_Properties = ' . var_export($injectedProperties, true) . ";\n";
     } else {
         $commandString = '';
     }
     return $commandString;
 }