function CustomAccessCheck::__construct

Same name and namespace in other branches
  1. 9 core/lib/Drupal/Core/Access/CustomAccessCheck.php \Drupal\Core\Access\CustomAccessCheck::__construct()
  2. 10 core/lib/Drupal/Core/Access/CustomAccessCheck.php \Drupal\Core\Access\CustomAccessCheck::__construct()
  3. 11.x core/lib/Drupal/Core/Access/CustomAccessCheck.php \Drupal\Core\Access\CustomAccessCheck::__construct()

Constructs a CustomAccessCheck instance.

Parameters

\Drupal\Core\Controller\ControllerResolverInterface $controller_resolver: The controller resolver.

\Drupal\Core\Access\AccessArgumentsResolverFactoryInterface $arguments_resolver_factory: The arguments resolver factory.

File

core/lib/Drupal/Core/Access/CustomAccessCheck.php, line 45

Class

CustomAccessCheck
Defines an access checker that allows specifying a custom method for access.

Namespace

Drupal\Core\Access

Code

public function __construct(ControllerResolverInterface $controller_resolver, AccessArgumentsResolverFactoryInterface $arguments_resolver_factory) {
    $this->controllerResolver = $controller_resolver;
    $this->argumentsResolverFactory = $arguments_resolver_factory;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.