Menu

## ResolverChain
in package
implements ParameterResolver

ResolverChain.php : 12

Dispatches the call to other resolvers until all parameters are resolved.

Chain of responsibility pattern.

### Table of Contents

#### Interfaces

ParameterResolver
  Resolves the parameters to use to call the callable.

#### Properties

$resolvers : array<string|int, ParameterResolver>

#### Methods

__construct() : mixed
appendResolver() : void
  Push a parameter resolver after the ones already registered.
getParameters() : array<string|int, mixed>
  Resolves the parameters to use to call the callable.
prependResolver() : void
  Insert a parameter resolver before the ones already registered.

### Properties

#### $resolvers

ResolverChain.php : 15
`private array<string|int, ParameterResolver> $resolvers`

### Methods

#### __construct()

ResolverChain.php : 17
`public __construct([array<string|int, mixed> $resolvers = [] ]) : mixed`

##### Parameters

$resolvers : array<string|int, mixed> = []

#### appendResolver()

ResolverChain.php : 49

Push a parameter resolver after the ones already registered.

`public appendResolver(ParameterResolver $resolver) : void`

##### Parameters

$resolver : ParameterResolver

#### getParameters()

ResolverChain.php : 22

Resolves the parameters to use to call the callable.

`public getParameters(ReflectionFunctionAbstract $reflection, array<string|int, mixed> $providedParameters, array<string|int, mixed> $resolvedParameters) : array<string|int, mixed>`

`$resolvedParameters` contains parameters that have already been resolved.

Each ParameterResolver must resolve parameters that are not already in `$resolvedParameters`. That allows to chain multiple ParameterResolver.

##### Parameters

$reflection : ReflectionFunctionAbstract

  Reflection object for the callable.

$providedParameters : array<string|int, mixed>

  Parameters provided by the caller.

$resolvedParameters : array<string|int, mixed>

  Parameters resolved (indexed by parameter position).

##### Return values

array<string|int, mixed>

#### prependResolver()

ResolverChain.php : 57

Insert a parameter resolver before the ones already registered.

`public prependResolver(ParameterResolver $resolver) : void`

##### Parameters

$resolver : ParameterResolver

## Search results