Copied!
CloneableInstantiable
Methods
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::__construct(array $parameters = [])
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::add(array $parameters) : void
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::all() : array
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::allDeprecated() : array
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::allNonEmpty() : array
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::cannotBeEmpty(string $name, string $message) : void
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::clear() : void
public clearUnusedEnvPlaceholders() : void
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::deprecate(string $name, string $package, string $version, string $message = 'The parameter "%s" is deprecated.') : void
 

Deprecates a service container parameter.

  • throws \ParameterNotFoundException if the parameter is not defined
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::escapeValue(?mixed $value) : ?mixed
public get(string $name) : UnitEnum|array|string|int|float|bool|?null
public getEnvPlaceholders() : array
 

Returns the map of env vars used in the resolved parameter values to their placeholders.

  • return string[][] A map of env var names to their placeholders
public getEnvPlaceholderUniquePrefix() : string
 

Gets the common env placeholder prefix for env vars created by this bag.

public getProvidedTypes() : array
 

Gets the PHP types corresponding to env() parameter prefixes.

  • return string[][]
public getUnusedEnvPlaceholders() : array
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::has(string $name) : bool
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::isResolved() : bool
public mergeEnvPlaceholders(self $bag) : void
 

Merges the env placeholders of another EnvPlaceholderParameterBag.

public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::remove(string $name) : void
public resolve() : void
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::resolveString(string $value, array $resolving = []) : ?mixed
 

Resolves parameters inside a string.

  • param array $resolving An array of keys that are being resolved (used internally to detect circular references)
  • throws \ParameterNotFoundException if a placeholder references a parameter that does not exist
  • throws \ParameterCircularReferenceException if a circular reference if detected
  • throws \RuntimeException when a given parameter has a type problem
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::resolveValue(?mixed $value, array $resolving = []) : ?mixed
 

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

  • template
  • param \TValue $value
  • param array $resolving An array of keys that are being resolved (used internally to detect circular references)
  • psalm-return (TValue is scalar ? array|scalar : array<array|scalar>)
  • throws \ParameterNotFoundException if a placeholder references a parameter that does not exist
  • throws \ParameterCircularReferenceException if a circular reference if detected
  • throws \RuntimeException when a given parameter has a type problem
public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::set(string $name, UnitEnum|array|string|int|float|bool|?null $value) : void
public setProvidedTypes(array $providedTypes) : void
 

Maps env prefixes to their corresponding PHP types.

public Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::unescapeValue(?mixed $value) : ?mixed
Properties
protected array Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::$deprecatedParameters = []
protected array Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::$nonEmptyParameters = []
protected array Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::$parameters = []
protected bool Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::$resolved = false
Properties
private static int $counter = 0
private array $envPlaceholders = []
private string $envPlaceholderUniquePrefix
private array $providedTypes = []
private array $unusedEnvPlaceholders = []
Properties
private static int $counter = 0
© 2025 Bruce Wells
Search Namespaces \ Classes
Configuration