function AccessCheck::create

Same name in other branches
  1. 10 core/modules/system/tests/modules/menu_test/src/Access/AccessCheck.php \Drupal\menu_test\Access\AccessCheck::create()
  2. 11.x core/modules/system/tests/modules/menu_test/src/Access/AccessCheck.php \Drupal\menu_test\Access\AccessCheck::create()

Overrides ContainerInjectionInterface::create

File

core/modules/system/tests/modules/menu_test/src/Access/AccessCheck.php, line 36

Class

AccessCheck
Checks access based on the 'menu_test' key in session.

Namespace

Drupal\menu_test\Access

Code

public static function create(ContainerInterface $container) {
    return new static($container->get('request_stack'));
}

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