ContainerBuilderInterface
interface ContainerBuilderInterface implements ContainerInterface (View source)
Methods
has(string $id)
bool
get(string $id)
mixed
set(string $id, callable|object|string $concrete)
void
singleton(string $id, callable|object|string $concrete)
void
scoped(string $id, callable|object|string $concrete)
void
transient(string $id, callable|object|string $concrete)
void
instance(string $id, object $instance)
void
tag(string $serviceId, string $tag)
void
singletonTagged(string $id, callable|object|string $concrete, string ...$tags)
Registers a singleton service and declares one or more collection capability tags.
void
alias(string $alias, string $target)
void
decorate(string $serviceId, string|callable $decorator, int $priority = 0)
void
when(string $consumer)
freeze()
Finalizes the registration plan and prohibits all further definition changes.
isFrozen()
bool
isBound(string $id)
Returns true only when the id is explicitly registered in the builder.
bool
Details
has
bool
has(string $id)
No description
get
mixed
get(string $id)
No description
set
void
set(string $id, callable|object|string $concrete)
No description
singleton
void
singleton(string $id, callable|object|string $concrete)
No description
scoped
void
scoped(string $id, callable|object|string $concrete)
No description
transient
void
transient(string $id, callable|object|string $concrete)
No description
instance
void
instance(string $id, object $instance)
No description
tag
void
tag(string $serviceId, string $tag)
No description
singletonTagged
void
singletonTagged(string $id, callable|object|string $concrete, string ...$tags)
Registers a singleton service and declares one or more collection capability tags.
alias
void
alias(string $alias, string $target)
No description
decorate
void
decorate(string $serviceId, string|callable $decorator, int $priority = 0)
No description
freeze
CompiledContainerPlan
freeze()
Finalizes the registration plan and prohibits all further definition changes.
isFrozen
bool
isFrozen()
No description
isBound
bool
isBound(string $id)
Returns true only when the id is explicitly registered in the builder.