interface ContainerBuilderInterface implements ContainerInterface (View source)

Methods

has(string $id)
bool
get(string $id)
mixed
void
set(string $id, callable|object|string $concrete)
void
void
singleton(string $id, callable|object|string $concrete)
void
void
scoped(string $id, callable|object|string $concrete)
void
void
transient(string $id, callable|object|string $concrete)
void
void
instance(string $id, object $instance)
void
void
tag(string $serviceId, string $tag)
void
void
singletonTagged(string $id, callable|object|string $concrete, string ...$tags)

Registers a singleton service and declares one or more collection capability tags.

void
void
alias(string $alias, string $target)
void
void
decorate(string $serviceId, string|callable $decorator, int $priority = 0)
void
freeze()

Finalizes the registration plan and prohibits all further definition changes.

bool
bool
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

Parameters

string $id

Return Value

bool

get

mixed get(string $id)

No description

Parameters

string $id

Return Value

mixed

set

void set(string $id, callable|object|string $concrete)

No description

Parameters

string $id
callable|object|string $concrete

Return Value

void

singleton

void singleton(string $id, callable|object|string $concrete)

No description

Parameters

string $id
callable|object|string $concrete

Return Value

void

scoped

void scoped(string $id, callable|object|string $concrete)

No description

Parameters

string $id
callable|object|string $concrete

Return Value

void

transient

void transient(string $id, callable|object|string $concrete)

No description

Parameters

string $id
callable|object|string $concrete

Return Value

void

instance

void instance(string $id, object $instance)

No description

Parameters

string $id
object $instance

Return Value

void

tag

void tag(string $serviceId, string $tag)

No description

Parameters

string $serviceId
string $tag

Return Value

void

singletonTagged

void singletonTagged(string $id, callable|object|string $concrete, string ...$tags)

Registers a singleton service and declares one or more collection capability tags.

Parameters

string $id
callable|object|string $concrete
string ...$tags

Return Value

void

alias

void alias(string $alias, string $target)

No description

Parameters

string $alias
string $target

Return Value

void

decorate

void decorate(string $serviceId, string|callable $decorator, int $priority = 0)

No description

Parameters

string $serviceId
string|callable $decorator
int $priority

Return Value

void

when

ContextualBindingBuilder when(string $consumer)

No description

Parameters

string $consumer

Return Value

ContextualBindingBuilder

compile

No description

Return Value

CompiledContainerPlan

freeze

Finalizes the registration plan and prohibits all further definition changes.

Return Value

CompiledContainerPlan

isFrozen

bool isFrozen()

No description

Return Value

bool

isBound

bool isBound(string $id)

Returns true only when the id is explicitly registered in the builder.

Parameters

string $id

Return Value

bool