Copied!

ParameterBagInterface is the interface implemented by objects that manage service container parameters.

Abstract Interface
Methods
public abstract add ( array $parameters )
 

Adds parameters to the service container parameters.

  • throws LogicException if the parameter cannot be added
public abstract all () : array
 

Gets the service container parameters.

public abstract clear ()
 

Clears all parameters.

  • throws LogicException if the ParameterBagInterface cannot be cleared
public abstract escapeValue ( ? mixed $value ) : ? mixed
 

Escape parameter placeholders %.

public abstract get ( string $name ) : UnitEnum | array | string | int | float | bool | null
 

Gets a service container parameter.

  • throws ParameterNotFoundException if the parameter is not defined
public abstract has ( string $name ) : bool
 

Returns true if a parameter name is defined.

public abstract remove ( string $name )
 

Removes a parameter.

public abstract resolve ()
 

Replaces parameter placeholders (%name%) by their values for all parameters.

public abstract resolveValue ( ? mixed $value )
 

Replaces parameter placeholders (%name%) by their values.

  • throws ParameterNotFoundException if a placeholder references a parameter that does not exist
public abstract set ( string $name , UnitEnum | array | string | int | float | bool | null $value )
 

Sets a service container parameter.

  • throws LogicException if the parameter cannot be set
public abstract unescapeValue ( ? mixed $value ) : ? mixed
 

Unescape parameter placeholders %.

© 2022 Bruce Wells
Search Namespaces \ Classes
Configuration