function MenuTestController::__construct

Same name in other branches
  1. 9 core/modules/system/tests/modules/menu_test/src/Controller/MenuTestController.php \Drupal\menu_test\Controller\MenuTestController::__construct()
  2. 8.9.x core/modules/system/tests/modules/menu_test/src/Controller/MenuTestController.php \Drupal\menu_test\Controller\MenuTestController::__construct()
  3. 10 core/modules/system/tests/modules/menu_test/src/Controller/MenuTestController.php \Drupal\menu_test\Controller\MenuTestController::__construct()

Constructs the MenuTestController object.

Parameters

\Drupal\Core\Theme\ThemeManagerInterface $theme_manager: The theme manager.

\Drupal\Core\Theme\ThemeNegotiatorInterface $theme_negotiator: The theme negotiator.

\Drupal\Core\Routing\RouteMatchInterface $route_match: The current route match.

File

core/modules/system/tests/modules/menu_test/src/Controller/MenuTestController.php, line 49

Class

MenuTestController
Controller routines for menu_test routes.

Namespace

Drupal\menu_test\Controller

Code

public function __construct(ThemeManagerInterface $theme_manager, ThemeNegotiatorInterface $theme_negotiator, RouteMatchInterface $route_match) {
    $this->themeManager = $theme_manager;
    $this->themeNegotiator = $theme_negotiator;
    $this->routeMatch = $route_match;
}

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