PipelineContainer
in package
Table of Contents
Properties
- $storage : array<class-string, mixed>
Methods
- clear() : void
- Removes all instances from the container.
- create() : T
- Creates an instance of class T and stores it in the container.
- get() : T
- Returns an instance of class T from the container.
- has() : bool
- Returns true if an instance of class T exists in the container.
- remove() : void
- Removes an instance of class T from the container.
- set() : void
- Sets an instance of class T in the container.
Properties
$storage
private
array<class-string, mixed>
$storage
= []
Methods
clear()
Removes all instances from the container.
public
clear() : void
create()
Creates an instance of class T and stores it in the container.
public
create(T> $className) : T
Parameters
- $className : T>
Tags
Return values
Tget()
Returns an instance of class T from the container.
public
get(T> $className) : T
Parameters
- $className : T>
Tags
Return values
Thas()
Returns true if an instance of class T exists in the container.
public
has(T> $className) : bool
Parameters
- $className : T>
Tags
Return values
boolremove()
Removes an instance of class T from the container.
public
remove(T> $className) : void
Parameters
- $className : T>
Tags
set()
Sets an instance of class T in the container.
public
set(T $instance) : void
Parameters
- $instance : T