PHP Класс Neos\Flow\ObjectManagement\Configuration\ConfigurationBuilder

Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
$reflectionService Neos\Flow\Reflection\ReflectionService
$systemLogger Neos\Flow\Log\SystemLoggerInterface

Открытые методы

Метод Описание
buildObjectConfigurations ( array $availableClassAndInterfaceNamesByPackage, array $rawObjectConfigurationsByPackages ) : array Traverses through the given class and interface names and builds a base object configuration for all of them. Then parses the provided extra configuration and merges the result into the overall configuration. Finally autowires dependencies of arguments and properties which can be resolved automatically.
injectReflectionService ( ReflectionService $reflectionService ) : void
injectSystemLogger ( Neos\Flow\Log\SystemLoggerInterface $systemLogger ) : void

Защищенные методы

Метод Описание
autowireArguments ( array &$objectConfigurations ) : void If mandatory constructor arguments have not been defined yet, this function tries to autowire them if possible.
autowireProperties ( array &$objectConfigurations ) : void This function tries to find yet unmatched dependencies which need to be injected via "inject*" setter methods.
enhanceRawConfigurationWithAnnotationOptions ( string $className, array $rawObjectConfiguration ) : array Builds a raw configuration array by parsing possible scope and autowiring annotations from the given class or interface.
parseArgumentOfTypeObject ( string $argumentName, mixed $objectNameOrConfiguration, string $configurationSourceHint ) : ConfigurationArgument Parses the configuration for arguments of type OBJECT
parseAutowiring ( mixed $value ) : integer Parses the value of the option "autowiring"
parseConfigurationArray ( string $objectName, array $rawConfigurationOptions, string $configurationSourceHint = '', Configuration $existingObjectConfiguration = null ) : Configuration Builds an object configuration object from a generic configuration container.
parsePropertyOfTypeObject ( string $propertyName, mixed $objectNameOrConfiguration, Configuration $parentObjectConfiguration ) : ConfigurationProperty Parses the configuration for properties of type OBJECT
parseScope ( string $value ) : integer Parses the value of the option "scope"

Описание методов

autowireArguments() защищенный Метод

If mandatory constructor arguments have not been defined yet, this function tries to autowire them if possible.
protected autowireArguments ( array &$objectConfigurations ) : void
$objectConfigurations array
Результат void

autowireProperties() защищенный Метод

This function tries to find yet unmatched dependencies which need to be injected via "inject*" setter methods.
protected autowireProperties ( array &$objectConfigurations ) : void
$objectConfigurations array
Результат void

buildObjectConfigurations() публичный Метод

Traverses through the given class and interface names and builds a base object configuration for all of them. Then parses the provided extra configuration and merges the result into the overall configuration. Finally autowires dependencies of arguments and properties which can be resolved automatically.
public buildObjectConfigurations ( array $availableClassAndInterfaceNamesByPackage, array $rawObjectConfigurationsByPackages ) : array
$availableClassAndInterfaceNamesByPackage array An array of available class names, grouped by package key
$rawObjectConfigurationsByPackages array An array of package keys and their raw (ie. unparsed) object configurations
Результат array

enhanceRawConfigurationWithAnnotationOptions() защищенный Метод

Builds a raw configuration array by parsing possible scope and autowiring annotations from the given class or interface.
protected enhanceRawConfigurationWithAnnotationOptions ( string $className, array $rawObjectConfiguration ) : array
$className string
$rawObjectConfiguration array
Результат array

injectReflectionService() публичный Метод

public injectReflectionService ( ReflectionService $reflectionService ) : void
$reflectionService Neos\Flow\Reflection\ReflectionService
Результат void

injectSystemLogger() публичный Метод

public injectSystemLogger ( Neos\Flow\Log\SystemLoggerInterface $systemLogger ) : void
$systemLogger Neos\Flow\Log\SystemLoggerInterface
Результат void

parseArgumentOfTypeObject() защищенный Метод

Parses the configuration for arguments of type OBJECT
protected parseArgumentOfTypeObject ( string $argumentName, mixed $objectNameOrConfiguration, string $configurationSourceHint ) : ConfigurationArgument
$argumentName string Name of the argument
$objectNameOrConfiguration mixed Value of the "object" section of the argument configuration - either a string or an array
$configurationSourceHint string A human readable hint on the original source of the configuration (for troubleshooting)
Результат ConfigurationArgument A configuration argument of type object

parseAutowiring() защищенный статический Метод

Parses the value of the option "autowiring"
protected static parseAutowiring ( mixed $value ) : integer
$value mixed Value of the option
Результат integer The autowiring option translated into one of Configuration::AUTOWIRING_MODE_*

parseConfigurationArray() защищенный Метод

Builds an object configuration object from a generic configuration container.
protected parseConfigurationArray ( string $objectName, array $rawConfigurationOptions, string $configurationSourceHint = '', Configuration $existingObjectConfiguration = null ) : Configuration
$objectName string Name of the object
$rawConfigurationOptions array The configuration array with options for the object configuration
$configurationSourceHint string A human readable hint on the original source of the configuration (for troubleshooting)
$existingObjectConfiguration Configuration If set, this object configuration object will be used instead of creating a fresh one
Результат Configuration The object configuration object

parsePropertyOfTypeObject() защищенный Метод

Parses the configuration for properties of type OBJECT
protected parsePropertyOfTypeObject ( string $propertyName, mixed $objectNameOrConfiguration, Configuration $parentObjectConfiguration ) : ConfigurationProperty
$propertyName string Name of the property
$objectNameOrConfiguration mixed Value of the "object" section of the property configuration - either a string or an array
$parentObjectConfiguration Configuration The Configuration object this property belongs to
Результат ConfigurationProperty A configuration property of type object

parseScope() защищенный Метод

Parses the value of the option "scope"
protected parseScope ( string $value ) : integer
$value string Value of the option
Результат integer The scope translated into a Configuration::SCOPE_* constant

Описание свойств

$reflectionService защищенное свойство

protected ReflectionService,Neos\Flow\Reflection $reflectionService
Результат Neos\Flow\Reflection\ReflectionService

$systemLogger защищенное свойство

protected SystemLoggerInterface,Neos\Flow\Log $systemLogger
Результат Neos\Flow\Log\SystemLoggerInterface