function ParameterBag::all
Same name in this branch
- 11.1.x vendor/symfony/dependency-injection/ParameterBag/ParameterBag.php \Symfony\Component\DependencyInjection\ParameterBag\ParameterBag::all()
Returns the parameters.
Parameters
string|null $key The name of the parameter to return or null to get them all:
2 calls to ParameterBag::all()
- MediaLibraryState::getAllowedTypeIds in core/
modules/ media_library/ src/ MediaLibraryState.php - Returns the media type IDs which can be selected.
- MediaLibraryState::getOpenerParameters in core/
modules/ media_library/ src/ MediaLibraryState.php - Returns all opener-specific parameter values.
File
-
vendor/
symfony/ http-foundation/ ParameterBag.php, line 36
Class
- ParameterBag
- ParameterBag is a container for key/value pairs.
Namespace
Symfony\Component\HttpFoundationCode
public function all(?string $key = null) : array {
if (null === $key) {
return $this->parameters;
}
if (!\is_array($value = $this->parameters[$key] ?? [])) {
throw new BadRequestException(\sprintf('Unexpected value for parameter "%s": expecting "array", got "%s".', $key, get_debug_type($value)));
}
return $value;
}