public function ContextActiveTrail::__construct in Context Active Trail 8
Same name and namespace in other branches
- 8.2 src/ContextActiveTrail.php \Drupal\context_active_trail\ContextActiveTrail::__construct()
Constructor.
Parameters
\Drupal\Core\Menu\MenuLinkManagerInterface $menu_link_manager: The menu link plugin manager.
\Drupal\Core\Routing\RouteMatchInterface $route_match: A route match object for finding the active link.
\Drupal\Core\Cache\CacheBackendInterface $cache: The cache backend.
\Drupal\Core\Lock\LockBackendInterface $lock: The lock backend.
\Drupal\Context\ContextManager $context_manager: The context manager.
Overrides MenuActiveTrail::__construct
File
- src/
ContextActiveTrail.php, line 38
Class
- ContextActiveTrail
- Allow the active trail to be set manually.
Namespace
Drupal\context_active_trailCode
public function __construct(MenuLinkManagerInterface $menu_link_manager, RouteMatchInterface $route_match, CacheBackendInterface $cache, LockBackendInterface $lock, ContextManager $context_manager) {
parent::__construct($menu_link_manager, $route_match, $cache, $lock);
$this->contextManager = $context_manager;
$this->tags[] = 'context_active_trail';
}