62 calls to AccessResult::allowed()

AccessAwareRouterTest::testMatchRequestAllowed in core/tests/Drupal/Tests/Core/Routing/AccessAwareRouterTest.php
Tests the matchRequest() function for access allowed.
AccessManager::check in core/lib/Drupal/Core/Access/AccessManager.php
Checks a route against applicable access check services.
AccessManagerTest::providerTestCheckConjunctions in core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php
Provides data for the conjunction test.
AccessManagerTest::testCheck in core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php
Tests \Drupal\Core\Access\AccessManager::check().
AccessManagerTest::testCheckNamedRoute in core/tests/Drupal/Tests/Core/Access/AccessManagerTest.php
Tests the checkNamedRoute method.
AccessResult::allowedIf in core/lib/Drupal/Core/Access/AccessResult.php
Creates an allowed or neutral access result.
AccessResult::andIf in core/lib/Drupal/Core/Access/AccessResult.php
Combine this access result with another using AND.
AccessResult::orIf in core/lib/Drupal/Core/Access/AccessResult.php
Combine this access result with another using OR.
AccessResultTest::andOrCacheabilityPropagationProvider in core/tests/Drupal/Tests/Core/Access/AccessResultTest.php
Provides a list of access result pairs and operations to test.
AccessResultTest::testAccessAllowed in core/tests/Drupal/Tests/Core/Access/AccessResultTest.php
@covers ::allowed[[api-linebreak]] @covers ::isAllowed[[api-linebreak]] @covers ::isForbidden[[api-linebreak]] @covers ::isNeutral[[api-linebreak]]
AccessResultTest::testAndIf in core/tests/Drupal/Tests/Core/Access/AccessResultTest.php
@covers ::andIf[[api-linebreak]]
AccessResultTest::testInheritCacheability in core/tests/Drupal/Tests/Core/Access/AccessResultTest.php
@covers ::inheritCacheability[[api-linebreak]]
AccessResultTest::testOrIf in core/tests/Drupal/Tests/Core/Access/AccessResultTest.php
@covers ::orIf[[api-linebreak]]
AccessResultTest::testOrIfCacheabilityMerging in core/tests/Drupal/Tests/Core/Access/AccessResultTest.php
@covers ::orIf[[api-linebreak]]
BlockPluginTrait::blockAccess in core/lib/Drupal/Core/Block/BlockPluginTrait.php
Indicates whether the block should be shown.
BlockRepositoryTest::providerBlocksConfig in core/modules/block/tests/src/Unit/BlockRepositoryTest.php
ContentEntityBaseUnitTest::testAccess in core/tests/Drupal/Tests/Core/Entity/ContentEntityBaseUnitTest.php
@covers ::access[[api-linebreak]]
ContextualLinkManagerTest::testGetContextualLinksArrayByGroup in core/tests/Drupal/Tests/Core/Menu/ContextualLinkManagerTest.php
Tests the getContextualLinksArrayByGroup method.
CsrfAccessCheck::access in core/lib/Drupal/Core/Access/CsrfAccessCheck.php
Checks access based on a CSRF token for the request.
CsrfRequestHeaderAccessCheck::access in core/lib/Drupal/Core/Access/CsrfRequestHeaderAccessCheck.php
Checks access.
CustomAccessCheckTest::testAccess in core/tests/Drupal/Tests/Core/Access/CustomAccessCheckTest.php
Tests the access method.
DefaultAccessCheck::access in core/lib/Drupal/Core/Access/DefaultAccessCheck.php
Checks access to the route based on the _access parameter.
DefaultAccessCheckTest::testAccess in core/tests/Drupal/Tests/Core/Access/DefaultAccessCheckTest.php
Tests the access method.
DefaultMenuLinkTreeManipulators::menuLinkCheckAccess in core/lib/Drupal/Core/Menu/DefaultMenuLinkTreeManipulators.php
Checks access for one menu link instance.
DefaultMenuLinkTreeManipulatorsTest::testCheckAccess in core/tests/Drupal/Tests/Core/Menu/DefaultMenuLinkTreeManipulatorsTest.php
Tests the checkAccess() tree manipulator.
DefaultMenuLinkTreeManipulatorsTest::testCheckAccessTreeManipulator in core/tests/Drupal/Tests/Core/Menu/DefaultMenuLinkTreeManipulatorsTest.php
Tests checkAccess() tree manipulator.
DefaultMenuLinkTreeManipulatorsTest::testCheckNodeAccess in core/tests/Drupal/Tests/Core/Menu/DefaultMenuLinkTreeManipulatorsTest.php
Tests the optimized node access checking.
DefinedTestAccessCheck::access in core/modules/system/tests/modules/router_test_directory/src/Access/DefinedTestAccessCheck.php
Checks access.
ElementTest::providerVisibleChildren in core/tests/Drupal/Tests/Core/Render/ElementTest.php
Data provider for testVisibleChildren.
EmailAction::access in core/lib/Drupal/Core/Action/Plugin/Action/EmailAction.php
Checks object access.
EntityAccessCheckTest::testAccess in core/tests/Drupal/Tests/Core/Entity/EntityAccessCheckTest.php
Tests the method for checking access to routes.
EntityAccessCheckTest::testAccessWithDifferentRouteParameters in core/tests/Drupal/Tests/Core/Entity/EntityAccessCheckTest.php
@covers ::access[[api-linebreak]]
EntityAccessCheckTest::testAccessWithTypePlaceholder in core/tests/Drupal/Tests/Core/Entity/EntityAccessCheckTest.php
@covers ::access[[api-linebreak]]
EntityAccessControlHandler::checkFieldAccess in core/lib/Drupal/Core/Entity/EntityAccessControlHandler.php
Default field access as determined by this access control handler.
EntityAccessControlHandler::fieldAccess in core/lib/Drupal/Core/Entity/EntityAccessControlHandler.php
Checks access to an operation on a given entity field.
EntityCreateAccessCheckTest::testAccess in core/tests/Drupal/Tests/Core/Entity/EntityCreateAccessCheckTest.php
Tests the method for checking access to routes.
EntityDeleteMultipleAccessCheck::access in core/lib/Drupal/Core/Entity/EntityDeleteMultipleAccessCheck.php
Checks if the user has delete access for at least one item of the store.
EntityListBuilderTest::testGetOperations in core/tests/Drupal/Tests/Core/Entity/EntityListBuilderTest.php
@covers ::getOperations[[api-linebreak]]
EntityPermissionsFormTest::testPermissionsByProvider in core/modules/user/tests/src/Unit/Form/EntityPermissionsFormTest.php
Tests generating the permissions list.
EntityTestAccessControlHandler::checkAccess in core/modules/system/tests/modules/entity_test/src/EntityTestAccessControlHandler.php
Performs access checks.
EntityUnitTest::testAccess in core/tests/Drupal/Tests/Core/Entity/EntityUnitTest.php
@covers ::access[[api-linebreak]]
entity_test_entity_access in core/modules/system/tests/modules/entity_test/entity_test.module
Implements hook_entity_access().
FieldAccessTest::testFieldAccess in core/tests/Drupal/KernelTests/Core/Field/FieldAccessTest.php
Tests hook_entity_field_access() and hook_entity_field_access_alter().
FieldItemList::defaultAccess in core/lib/Drupal/Core/Field/FieldItemList.php
Contains the default access logic of this field.
FormBuilderTest::providerTestChildAccessInheritance in core/tests/Drupal/Tests/Core/Form/FormBuilderTest.php
Data provider for testChildAccessInheritance.
GotoAction::access in core/lib/Drupal/Core/Action/Plugin/Action/GotoAction.php
Checks object access.
LocalTaskManagerTest::setupFactoryAndLocalTaskPlugins in core/tests/Drupal/Tests/Core/Menu/LocalTaskManagerTest.php
MenuUiMenuTreeManipulators::checkAccess in core/modules/menu_ui/src/Menu/MenuUiMenuTreeManipulators.php
Grants access to a menu tree when used in the menu management form.
MessageAction::access in core/lib/Drupal/Core/Action/Plugin/Action/MessageAction.php
Checks object access.
NoType::access in core/modules/system/tests/modules/action_test/src/Plugin/Action/NoType.php
Checks object access.
PathFieldItemList::defaultAccess in core/modules/path/src/Plugin/Field/FieldType/PathFieldItemList.php
Contains the default access logic of this field.
RendererTest::providerAccessValues in core/tests/Drupal/Tests/Core/Render/RendererTest.php
Provides a list of both booleans.
RendererTest::testRenderWithAccessControllerResolved in core/tests/Drupal/Tests/Core/Render/RendererTest.php
@covers ::render[[api-linebreak]] @covers ::doRender[[api-linebreak]]
SystemAdminMenuBlockAccessCheck::hasAccessToChildMenuItems in core/modules/system/src/Access/SystemAdminMenuBlockAccessCheck.php
Check that the given route has access to child routes.
TestAccessClass::accessResultAllowed in core/tests/Drupal/Tests/Core/Render/RendererTest.php
TestAction::access in core/modules/views/tests/modules/action_bulk_test/src/Plugin/Action/TestAction.php
Checks object access.
TestController::accessAllow in core/tests/Drupal/Tests/Core/Access/CustomAccessCheckTest.php
Url::access in core/lib/Drupal/Core/Url.php
Checks this Url object against applicable access check services.
UserAccessControlHandler::checkAccess in core/modules/user/src/UserAccessControlHandler.php
Performs access checks.
UserAccessControlHandler::checkFieldAccess in core/modules/user/src/UserAccessControlHandler.php
Default field access as determined by this access control handler.
UserAccessControlHandlerTest::setUp in core/modules/user/tests/src/Unit/UserAccessControlHandlerTest.php
UserPermissionsModuleSpecificForm::access in core/modules/user/src/Form/UserPermissionsModuleSpecificForm.php
Checks that at least one module defines permissions.

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