Property | Type | Description | |
---|---|---|---|
$arguments |
Method | Description | |
---|---|---|
__construct ( string | null $class = null, array $arguments = [] ) | ||
addArgument ( mixed $argument ) : |
Adds an argument to pass to the service constructor/factory method. | |
addAutowiringType ( string $type ) : |
Adds a type that will default to this definition. | |
addMethodCall ( string $method, array $arguments = [] ) : |
Adds a method to call after service initialization. | |
addTag ( string $name, array $attributes = [] ) : |
Adds a tag for this definition. | |
clearTag ( string $name ) : |
Clears all tags for a given name. | |
clearTags ( ) : |
Clears the tags for this definition. | |
getArgument ( integer $index ) : mixed | Gets an argument to pass to the service constructor/factory method. | |
getArguments ( ) : array | Gets the arguments to pass to the service constructor/factory method. | |
getAutowiredMethods ( ) : string[] | Gets autowired methods. | |
getAutowiringTypes ( ) : string[] | Gets autowiring types that will default to this definition. | |
getClass ( ) : string | null | Gets the service class. | |
getConfigurator ( ) : callable | null | Gets the configurator to call after the service is fully initialized. | |
getDecoratedService ( ) : null | array | Gets the service that decorates this service. | |
getDeprecationMessage ( string $id ) : string | Message to use if this definition is deprecated. | |
getFactory ( ) : string | array | Gets the factory. | |
getFile ( ) : string | null | Gets the file to require before creating the service. | |
getMethodCalls ( ) : array | Gets the methods to call after service initialization. | |
getProperties ( ) | ||
getTag ( string $name ) : array | Gets a tag by name. | |
getTags ( ) : array | Returns all tags. | |
hasAutowiringType ( string $type ) : boolean | Will this definition default for the given type? | |
hasMethodCall ( string $method ) : boolean | Check if the current definition has a given method to call after service initialization. | |
hasTag ( string $name ) : boolean | Whether this definition has a tag with the given name. | |
isAbstract ( ) : boolean | Whether this definition is abstract, that means it merely serves as a template for other definitions. | |
isAutowired ( ) : boolean | Is the definition autowired? | |
isDeprecated ( ) : boolean | Whether this definition is deprecated, that means it should not be called anymore. | |
isLazy ( ) : boolean | Whether this service is lazy. | |
isPublic ( ) : boolean | Whether this service is public facing. | |
isShared ( ) : boolean | Whether this service is shared. | |
isSynthetic ( ) : boolean | Whether this definition is synthetic, that is not constructed by the container, but dynamically injected. | |
removeAutowiringType ( string $type ) : |
Removes a type. | |
removeMethodCall ( string $method ) : |
Removes a method to call after service initialization. | |
replaceArgument ( integer $index, mixed $argument ) : |
Sets a specific argument. | |
setAbstract ( boolean $boolean ) : |
Whether this definition is abstract, that means it merely serves as a template for other definitions. | |
setArguments ( array $arguments ) : |
Sets the arguments to pass to the service constructor/factory method. | |
setAutowired ( boolean $autowired ) : |
Sets autowired. | |
setAutowiredMethods ( array $autowiredMethods ) : |
Sets autowired methods. | |
setAutowiringTypes ( array $types ) : |
Sets types that will default to this definition. | |
setClass ( string $class ) : |
Sets the service class. | |
setConfigurator ( string | array $configurator ) : |
Sets a configurator to call after the service is fully initialized. | |
setDecoratedService ( null | string $id, null | string $renamedId = null, integer $priority ) : |
Sets the service that this service is decorating. | |
setDeprecated ( boolean $status = true, string $template = null ) : |
Whether this definition is deprecated, that means it should not be called anymore. | |
setFactory ( string | array $factory ) : |
Sets a factory. | |
setFile ( string $file ) : |
Sets a file to require before creating the service. | |
setLazy ( boolean $lazy ) : |
Sets the lazy flag of this service. | |
setMethodCalls ( array $calls = [] ) : |
Sets the methods to call after service initialization. | |
setProperties ( array $properties ) | ||
setProperty ( $name, $value ) | ||
setPublic ( boolean $boolean ) : |
Sets the visibility of this service. | |
setShared ( boolean $shared ) : |
Sets if the service must be shared or not. | |
setSynthetic ( boolean $boolean ) : |
Sets whether this definition is synthetic, that is not constructed by the container, but dynamically injected. | |
setTags ( array $tags ) : |
Sets tags for this definition. |
public addArgument ( mixed $argument ) : |
||
$argument | mixed | An argument |
return | The current instance |
public addAutowiringType ( string $type ) : |
||
$type | string | |
return | The current instance |
public addMethodCall ( string $method, array $arguments = [] ) : |
||
$method | string | The method name to call |
$arguments | array | An array of arguments to pass to the method call |
return | The current instance |
public clearTags ( ) : |
||
return | The current instance |
public getArgument ( integer $index ) : mixed | ||
$index | integer | |
return | mixed | The argument value |
public getArguments ( ) : array | ||
return | array | The array of arguments |
public getAutowiredMethods ( ) : string[] | ||
return | string[] |
public getAutowiringTypes ( ) : string[] | ||
return | string[] |
public getConfigurator ( ) : callable | null | ||
return | callable | null | The PHP callable to call |
public getDecoratedService ( ) : null | array | ||
return | null | array | An array composed of the decorated service id, the new id for it and the priority of decoration, null if no service is decorated |
public getDeprecationMessage ( string $id ) : string | ||
$id | string | Service id relying on this definition |
return | string |
public getFactory ( ) : string | array | ||
return | string | array | The PHP function or an array containing a class/Reference and a method to call |
public getMethodCalls ( ) : array | ||
return | array | An array of method calls |
public hasAutowiringType ( string $type ) : boolean | ||
$type | string | |
return | boolean |
public hasMethodCall ( string $method ) : boolean | ||
$method | string | The method name to search for |
return | boolean |
public isAbstract ( ) : boolean | ||
return | boolean |
public isAutowired ( ) : boolean | ||
return | boolean |
public isDeprecated ( ) : boolean | ||
return | boolean |
public isSynthetic ( ) : boolean | ||
return | boolean |
public removeAutowiringType ( string $type ) : |
||
$type | string | |
return | The current instance |
public removeMethodCall ( string $method ) : |
||
$method | string | The method name to remove |
return | The current instance |
public replaceArgument ( integer $index, mixed $argument ) : |
||
$index | integer | |
$argument | mixed | |
return | The current instance |
public setAbstract ( boolean $boolean ) : |
||
$boolean | boolean | |
return | the current instance |
public setArguments ( array $arguments ) : |
||
$arguments | array | An array of arguments |
return | The current instance |
public setAutowired ( boolean $autowired ) : |
||
$autowired | boolean | |
return | The current instance |
public setAutowiredMethods ( array $autowiredMethods ) : |
||
$autowiredMethods | array | |
return | The current instance |
public setAutowiringTypes ( array $types ) : |
||
$types | array | |
return | The current instance |
public setConfigurator ( string | array $configurator ) : |
||
$configurator | string | array | A PHP callable |
return | The current instance |
public setDecoratedService ( null | string $id, null | string $renamedId = null, integer $priority ) : |
||
$id | null | string | The decorated service id, use null to remove decoration |
$renamedId | null | string | The new decorated service id |
$priority | integer | The priority of decoration |
return | The current instance |
public setDeprecated ( boolean $status = true, string $template = null ) : |
||
$status | boolean | |
$template | string | Template message to use if the definition is deprecated |
return | the current instance |
public setFactory ( string | array $factory ) : |
||
$factory | string | array | A PHP function or an array containing a class/Reference and a method to call |
return | The current instance |
public setMethodCalls ( array $calls = [] ) : |
||
$calls | array | An array of method calls |
return | The current instance |
public setSynthetic ( boolean $boolean ) : |
||
$boolean | boolean | |
return | the current instance |