You are here

public function AccordionMenusBlock::__construct in Accordion Menus 8.2

Same name in this branch
  1. 8.2 src/Plugin/Derivative/AccordionMenusBlock.php \Drupal\accordion_menus\Plugin\Derivative\AccordionMenusBlock::__construct()
  2. 8.2 src/Plugin/Block/AccordionMenusBlock.php \Drupal\accordion_menus\Plugin\Block\AccordionMenusBlock::__construct()
Same name and namespace in other branches
  1. 8.4 src/Plugin/Block/AccordionMenusBlock.php \Drupal\accordion_menus\Plugin\Block\AccordionMenusBlock::__construct()
  2. 8.3 src/Plugin/Block/AccordionMenusBlock.php \Drupal\accordion_menus\Plugin\Block\AccordionMenusBlock::__construct()

Constructs a new AccordionMenuBlock.

Parameters

array $configuration: A configuration array containing information about the plugin instance.

string $plugin_id: The plugin_id for the plugin instance.

array $plugin_definition: The plugin implementation definition.

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

Overrides BlockPluginTrait::__construct

File

src/Plugin/Block/AccordionMenusBlock.php, line 42

Class

AccordionMenusBlock
Provides a accordion Menu block.

Namespace

Drupal\accordion_menus\Plugin\Block

Code

public function __construct(array $configuration, $plugin_id, array $plugin_definition, MenuLinkTreeInterface $menu_tree) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this->menuTree = $menu_tree;
}