You are here

public function DataPolicyInformBlock::__construct in Data Policy 8

Constructs a new DataPolicyInformBlock 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.

\Symfony\Component\HttpFoundation\RequestStack $request_stack: The request stack.

\Drupal\Core\Path\CurrentPathStack $current_path: The current path.

\Drupal\Core\Path\AliasManagerInterface $alias_manager: An alias manager to find the alias for the current system path.

\Drupal\Core\Path\PathMatcherInterface $path_matcher: The path matcher service.

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

Overrides BlockPluginTrait::__construct

File

src/Plugin/Block/DataPolicyInformBlock.php, line 88

Class

DataPolicyInformBlock
Provides a 'Data Policy' block.

Namespace

Drupal\data_policy\Plugin\Block

Code

public function __construct(array $configuration, $plugin_id, $plugin_definition, RequestStack $request_stack, CurrentPathStack $current_path, AliasManagerInterface $alias_manager, PathMatcherInterface $path_matcher, EntityTypeManagerInterface $entity_type_manager) {
  parent::__construct($configuration, $plugin_id, $plugin_definition);
  $this->requestStack = $request_stack;
  $this->currentPath = $current_path;
  $this->aliasManager = $alias_manager;
  $this->pathMatcher = $path_matcher;
  $this->entityTypeManager = $entity_type_manager;
}