You are here

public function GroupInterface::hasPermission in Group 8

Same name and namespace in other branches
  1. 2.0.x src/Entity/GroupInterface.php \Drupal\group\Entity\GroupInterface::hasPermission()

Checks whether a user has the requested permission.

Parameters

string $permission: The permission to check for.

\Drupal\Core\Session\AccountInterface $account: The account for which to check a permission.

Return value

bool Whether the user has the requested permission.

1 method overrides GroupInterface::hasPermission()
Group::hasPermission in src/Entity/Group.php
Checks whether a user has the requested permission.

File

src/Entity/GroupInterface.php, line 153

Class

GroupInterface
Provides an interface defining a Group entity.

Namespace

Drupal\group\Entity

Code

public function hasPermission($permission, AccountInterface $account);