Menu

## TypeHintContainerResolver
in package
implements ParameterResolver

TypeHintContainerResolver.php : 13

Inject entries from a DI container using the type-hints.

### Table of Contents

#### Interfaces

ParameterResolver
  Resolves the parameters to use to call the callable.

#### Properties

$container : ContainerInterface

#### Methods

__construct() : mixed
getParameters() : array<string|int, mixed>
  Resolves the parameters to use to call the callable.

### Properties

#### $container

TypeHintContainerResolver.php : 16
`private ContainerInterface $container`

### Methods

#### __construct()

TypeHintContainerResolver.php : 21
`public __construct(ContainerInterface $container) : mixed`

##### Parameters

$container : ContainerInterface

  The container to get entries from.

#### getParameters()

TypeHintContainerResolver.php : 26

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>

## Search results