You are here

interface GroupPermissionCheckerInterface in Group 8

Same name and namespace in other branches
  1. 2.0.x src/Access/GroupPermissionCheckerInterface.php \Drupal\group\Access\GroupPermissionCheckerInterface

Defines the group permission checker interface.

Hierarchy

Expanded class hierarchy of GroupPermissionCheckerInterface

All classes that implement GroupPermissionCheckerInterface

File

src/Access/GroupPermissionCheckerInterface.php, line 11

Namespace

Drupal\group\Access
View source
interface GroupPermissionCheckerInterface {

  /**
   * Checks whether an account has a permission in a group.
   *
   * @param string $permission
   *   The name of the permission to check for.
   * @param \Drupal\Core\Session\AccountInterface $account
   *   The user account for which to check the group permissions.
   * @param \Drupal\group\Entity\GroupInterface $group
   *   The group to check the permission against.
   *
   * @return bool
   *   Whether the account has the group permission.
   */
  public function hasPermissionInGroup($permission, AccountInterface $account, GroupInterface $group);

}

Members

Namesort descending Modifiers Type Description Overrides
GroupPermissionCheckerInterface::hasPermissionInGroup public function Checks whether an account has a permission in a group. 1