You are here

public function MenuLinkContentAccessControlHandler::__construct in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/menu_link_content/src/MenuLinkContentAccessControlHandler.php \Drupal\menu_link_content\MenuLinkContentAccessControlHandler::__construct()
  2. 10 core/modules/menu_link_content/src/MenuLinkContentAccessControlHandler.php \Drupal\menu_link_content\MenuLinkContentAccessControlHandler::__construct()

Creates a new MenuLinkContentAccessControlHandler.

Parameters

\Drupal\Core\Entity\EntityTypeInterface $entity_type: The entity type definition.

\Drupal\Core\Access\AccessManagerInterface $access_manager: The access manager to check routes by name.

Overrides EntityAccessControlHandler::__construct

File

core/modules/menu_link_content/src/MenuLinkContentAccessControlHandler.php, line 34

Class

MenuLinkContentAccessControlHandler
Defines the access control handler for the user entity type.

Namespace

Drupal\menu_link_content

Code

public function __construct(EntityTypeInterface $entity_type, AccessManagerInterface $access_manager) {
  parent::__construct($entity_type);
  $this->accessManager = $access_manager;
}