function ParamConverterManager::addConverter

Same name in other branches
  1. 9 core/lib/Drupal/Core/ParamConverter/ParamConverterManager.php \Drupal\Core\ParamConverter\ParamConverterManager::addConverter()
  2. 8.9.x core/lib/Drupal/Core/ParamConverter/ParamConverterManager.php \Drupal\Core\ParamConverter\ParamConverterManager::addConverter()
  3. 11.x core/lib/Drupal/Core/ParamConverter/ParamConverterManager.php \Drupal\Core\ParamConverter\ParamConverterManager::addConverter()

File

core/lib/Drupal/Core/ParamConverter/ParamConverterManager.php, line 26

Class

ParamConverterManager
Manages converter services for converting request parameters to full objects.

Namespace

Drupal\Core\ParamConverter

Code

public function addConverter(ParamConverterInterface $param_converter, $id) {
    $this->converters[$id] = $param_converter;
    return $this;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.