function Container::getParameter
Same name in other branches
- 9 core/lib/Drupal/Component/DependencyInjection/Container.php \Drupal\Component\DependencyInjection\Container::getParameter()
- 8.9.x core/lib/Drupal/Component/DependencyInjection/Container.php \Drupal\Component\DependencyInjection\Container::getParameter()
- 11.x core/lib/Drupal/Component/DependencyInjection/Container.php \Drupal\Component\DependencyInjection\Container::getParameter()
2 calls to Container::getParameter()
- Container::resolveServicesAndParameters in core/
lib/ Drupal/ Component/ DependencyInjection/ Container.php - Resolves arguments that represent services or variables to the real values.
- PhpArrayContainer::resolveServicesAndParameters in core/
lib/ Drupal/ Component/ DependencyInjection/ PhpArrayContainer.php
File
-
core/
lib/ Drupal/ Component/ DependencyInjection/ Container.php, line 327
Class
- Container
- Provides a container optimized for Drupal's needs.
Namespace
Drupal\Component\DependencyInjectionCode
public function getParameter($name) : array|bool|string|int|float|null {
if (!\array_key_exists($name, $this->parameters)) {
if (!$name) {
throw new ParameterNotFoundException('');
}
throw new ParameterNotFoundException($name, NULL, NULL, NULL, $this->getParameterAlternatives($name));
}
return $this->parameters[$name];
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.