PHP 클래스 Cascade\Config\Loader\ClassLoader\Resolver\ExtraOptionsResolver

저자: Raphael Antonmattei ([email protected])
파일 보기 프로젝트 열기: theorchard/monolog-cascade 1 사용 예제들

보호된 프로퍼티들

프로퍼티 타입 설명
$params array Associative array of parameters to resolve against
$reflected ReflectionClass Reflection class for which you want to resolve extra options

공개 메소드들

메소드 설명
__construct ( ReflectionClass $reflected, array $params = [] ) Constructor
generateParamsHashKey ( $params ) : string Generate a unique hash based on the keys of the extra params
getParams ( ) : array Get the parameters we want to resolve against
getReflected ( ) : ReflectionClass Returns the reflected object
resolve ( array $options, ClassLoader $classLoader = null ) : array Resolve options against extra params requirements
setParams ( array $params = [] ) Set the parameters we want to resolve against

보호된 메소드들

메소드 설명
configureOptions ( Symfony\Component\OptionsResolver\OptionsResolver $resolver, ClassLoader $classLoader = null ) Configure options for the provided OptionResolver to match extra params requirements

메소드 상세

__construct() 공개 메소드

Constructor
public __construct ( ReflectionClass $reflected, array $params = [] )
$reflected ReflectionClass Reflection class for which you want to resolve extra options
$params array Associative array of extra parameters we want to resolve against

configureOptions() 보호된 메소드

Configure options for the provided OptionResolver to match extra params requirements
protected configureOptions ( Symfony\Component\OptionsResolver\OptionsResolver $resolver, ClassLoader $classLoader = null )
$resolver Symfony\Component\OptionsResolver\OptionsResolver
$classLoader Cascade\Config\Loader\ClassLoader Optional class loader if you want to use custom handlers for some of the extra options

generateParamsHashKey() 공개 정적인 메소드

Generate a unique hash based on the keys of the extra params
public static generateParamsHashKey ( $params ) : string
리턴 string Unique MD5 hash

getParams() 공개 메소드

Get the parameters we want to resolve against
public getParams ( ) : array
리턴 array $params Associative array of parameters

getReflected() 공개 메소드

Returns the reflected object
public getReflected ( ) : ReflectionClass
리턴 ReflectionClass

resolve() 공개 메소드

Resolve options against extra params requirements
public resolve ( array $options, ClassLoader $classLoader = null ) : array
$options array Array of option values
$classLoader Cascade\Config\Loader\ClassLoader Optional class loader if you want to use custom handlers to resolve the extra options
리턴 array Array of resolved options

setParams() 공개 메소드

Set the parameters we want to resolve against
public setParams ( array $params = [] )
$params array Associative array of extra parameters we want to resolve against

프로퍼티 상세

$params 보호되어 있는 프로퍼티

Associative array of parameters to resolve against
protected array $params
리턴 array

$reflected 보호되어 있는 프로퍼티

Reflection class for which you want to resolve extra options
protected ReflectionClass $reflected
리턴 ReflectionClass