function HelpController::__construct
Same name in other branches
- 9 core/modules/help/src/Controller/HelpController.php \Drupal\help\Controller\HelpController::__construct()
- 10 core/modules/help/src/Controller/HelpController.php \Drupal\help\Controller\HelpController::__construct()
- 11.x core/modules/help/src/Controller/HelpController.php \Drupal\help\Controller\HelpController::__construct()
Creates a new HelpController.
Parameters
\Drupal\Core\Routing\RouteMatchInterface $route_match: The current route match.
\Drupal\help\HelpSectionManager $help_manager: The help section manager.
\Drupal\Core\Extension\ModuleExtensionList|null $module_extension_list: The module extension list. This is left optional for BC reasons, but the optional usage is deprecated and will become required in Drupal 9.0.0.
File
-
core/
modules/ help/ src/ Controller/ HelpController.php, line 50
Class
- HelpController
- Controller routines for help routes.
Namespace
Drupal\help\ControllerCode
public function __construct(RouteMatchInterface $route_match, HelpSectionManager $help_manager, ModuleExtensionList $module_extension_list = NULL) {
$this->routeMatch = $route_match;
$this->helpManager = $help_manager;
if ($module_extension_list === NULL) {
@trigger_error('Calling HelpController::__construct() with the $module_extension_list argument is supported in drupal:8.8.0 and will be required before drupal:9.0.0. See https://www.drupal.org/node/2709919.', E_USER_DEPRECATED);
$module_extension_list = \Drupal::service('extension.list.module');
}
$this->moduleExtensionList = $module_extension_list;
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.