W3cubDocs

/Drupal 8

public function AccessResultInterface::isForbidden

public AccessResultInterface::isForbidden()

Checks whether this access result indicates access is explicitly forbidden.

This is a kill switch — both orIf() and andIf() will result in isForbidden() if either results are isForbidden().

Return value

bool When TRUE then isAllowed() and isNeutral() are FALSE.

File

core/lib/Drupal/Core/Access/AccessResultInterface.php, line 40

Class

AccessResultInterface
Interface for access result value objects.

Namespace

Drupal\Core\Access

Code

public function isForbidden();

© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Access!AccessResultInterface.php/function/AccessResultInterface::isForbidden/8.1.x