function RoleInterface::grantPermissions
Grants permissions to the role.
Parameters
array $permissions: The permissions to grant.
Return value
$this
1 method overrides RoleInterface::grantPermissions()
- Role::grantPermissions in core/
modules/ user/ src/ Entity/ Role.php - Grants permissions to the role.
File
-
core/
modules/ user/ src/ RoleInterface.php, line 62
Class
- RoleInterface
- Provides an interface defining a user role entity.
Namespace
Drupal\userCode
public function grantPermissions(array $permissions) : static;
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.