You are here

public function UltimenuManager::__construct in Ultimenu 8

Same name and namespace in other branches
  1. 8.2 src/UltimenuManager.php \Drupal\ultimenu\UltimenuManager::__construct()

Constructs a UltimenuManager object.

Parameters

\Drupal\Core\Entity\EntityTypeManagerInterface $entity_type_manager: The entity type manager service.

\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The factory for configuration objects.

\Drupal\Core\Extension\ModuleHandlerInterface $module_handler: The module handler.

\Drupal\Core\Extension\ThemeHandlerInterface $theme_handler: The theme handler.

\Drupal\Core\Menu\MenuLinkTreeInterface $menu_tree: The menu tree manager.

\Drupal\Core\Menu\MenuActiveTrailInterface $menu_active_trail: The active menu trail service.

\Drupal\Core\Cache\CacheBackendInterface $cache_backend: The cache backend.

Overrides DefaultPluginManager::__construct

File

src/UltimenuManager.php, line 139

Class

UltimenuManager
Manages Ultimenu plugin.

Namespace

Drupal\ultimenu

Code

public function __construct(EntityTypeManagerInterface $entity_type_manager, ConfigFactoryInterface $config_factory, ModuleHandlerInterface $module_handler, ThemeHandlerInterface $theme_handler, MenuLinkTreeInterface $menu_tree, MenuActiveTrailInterface $menu_active_trail, CacheBackendInterface $cache_backend) {
  $this->entityTypeManager = $entity_type_manager;
  $this->configFactory = $config_factory;
  $this->moduleHandler = $module_handler;
  $this->themeHandler = $theme_handler;
  $this->menuTree = $menu_tree;
  $this->menuActiveTrail = $menu_active_trail;
  $this
    ->setCacheBackend($cache_backend, 'ultimenu', [
    'ultimenu',
  ]);
  $this
    ->alterInfo('ultimenu_info');
}