public function ParamConverterManager::getConverter in Drupal 10
Same name and namespace in other branches
- 8 core/lib/Drupal/Core/ParamConverter/ParamConverterManager.php \Drupal\Core\ParamConverter\ParamConverterManager::getConverter()
- 9 core/lib/Drupal/Core/ParamConverter/ParamConverterManager.php \Drupal\Core\ParamConverter\ParamConverterManager::getConverter()
File
- core/
lib/ Drupal/ Core/ ParamConverter/ ParamConverterManager.php, line 34
Class
- ParamConverterManager
- Manages converter services for converting request parameters to full objects.
Namespace
Drupal\Core\ParamConverterCode
public function getConverter($converter) {
if (isset($this->converters[$converter])) {
return $this->converters[$converter];
}
else {
throw new \InvalidArgumentException(sprintf('No converter has been registered for %s', $converter));
}
}