Maker

 class Winter\Storm\Foundation\Maker

Properties

protected $app : Application

protected $bindings : array

Methods

public __construct (Winter\Storm\Foundation\Application $app) : void

Maker constructor.

Parameters
Property Description
$app
Winter\Storm\Foundation\Application
Returns
void

public bind ($abstract, Closure $concrete)

Parameters
Property Description
$abstract
mixed
$concrete
Closure
Returns
mixed

public make ($abstract, array $parameters = [])

Parameters
Property Description
$abstract
mixed
$parameters
array
Returns
mixed

protected build ($concrete, $parameters)

Parameters
Property Description
$concrete
mixed
$parameters
mixed
Returns
mixed

protected getBinding ($abstract)

Parameters
Property Description
$abstract
mixed
Returns
mixed

protected getDependencies (array $parameters, array $primitives = []) : array

Resolve all of the dependencies from the ReflectionParameters.

Parameters
Property Description
$parameters
array
$primitives
array
Returns
array

protected getFromContainer (string $abstract) : mixed

Parameters
Property Description
$abstract
string
Returns
mixed

protected isBound ($abstract) : bool

Parameters
Property Description
$abstract
mixed
Returns
bool

protected keyParametersByArgument (array $dependencies, array $parameters) : array

If extra parameters are passed by numeric ID, rekey them by argument name.

Parameters
Property Description
$dependencies
array
$parameters
array
Returns
array

protected resolveClass (ReflectionParameter $parameter) : mixed

Parameters
Property Description
$parameter
ReflectionParameter
Returns
mixed

protected resolvePrimitive (ReflectionParameter $parameter) : mixed | void

Parameters
Property Description
$parameter
ReflectionParameter
Returns
mixed | void

protected unresolvablePrimitive (ReflectionParameter $parameter)

Parameters
Property Description
$parameter
ReflectionParameter
Returns
mixed
Copyright © 2024 Winter CMS