You are here

public function BookNavigationBlock::__construct in Drupal 10

Same name and namespace in other branches
  1. 8 core/modules/book/src/Plugin/Block/BookNavigationBlock.php \Drupal\book\Plugin\Block\BookNavigationBlock::__construct()
  2. 9 core/modules/book/src/Plugin/Block/BookNavigationBlock.php \Drupal\book\Plugin\Block\BookNavigationBlock::__construct()

Constructs a new BookNavigationBlock instance.

Parameters

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

string $plugin_id: The plugin_id for the plugin instance.

mixed $plugin_definition: The plugin implementation definition.

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

\Drupal\book\BookManagerInterface $book_manager: The book manager.

\Drupal\Core\Entity\EntityStorageInterface $node_storage: The node storage.

File

core/modules/book/src/Plugin/Block/BookNavigationBlock.php, line 63

Class

BookNavigationBlock
Provides a 'Book navigation' block.

Namespace

Drupal\book\Plugin\Block

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, RouteMatchInterface $route_match, BookManagerInterface $book_manager, EntityStorageInterface $node_storage) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this->routeMatch = $route_match;
  $this->bookManager = $book_manager;
  $this->nodeStorage = $node_storage;
}