ContextualBindingBuilder
class ContextualBindingBuilder implements ContextualBindingBuilder
Properties
| protected string | $needs | The abstract target. |
Methods
needs(string $abstract)
Define the abstract target that depends on the context.
give(mixed $implementation)
Define the implementation for the contextual binding.
giveTagged(string $tag)
Define tagged services to be used as the implementation for the contextual binding.
giveConfig(string $key, mixed $default = null)
Specify the configuration item to bind as a primitive.
Details
at line 20
__construct(Container $container, string|array $concrete)
Create a new contextual binding builder.
at line 29
ContextualBindingBuilder
needs(string $abstract)
Define the abstract target that depends on the context.
at line 39
ContextualBindingBuilder
give(mixed $implementation)
Define the implementation for the contextual binding.
at line 51
ContextualBindingBuilder
giveTagged(string $tag)
Define tagged services to be used as the implementation for the contextual binding.
at line 63
ContextualBindingBuilder
giveConfig(string $key, mixed $default = null)
Specify the configuration item to bind as a primitive.