interface PermissionInterface in Organic groups 8
Interface for OG permission classes.
Hierarchy
- interface \Drupal\og\PermissionInterface
Expanded class hierarchy of PermissionInterface
All classes that implement PermissionInterface
3 files declare their use of PermissionInterface
- PermissionEvent.php in src/
Event/ PermissionEvent.php - PermissionEventInterface.php in src/
Event/ PermissionEventInterface.php - PermissionEventTest.php in tests/
src/ Kernel/ PermissionEventTest.php
File
- src/
PermissionInterface.php, line 10
Namespace
Drupal\ogView source
interface PermissionInterface {
/**
* Returns the value for the given property.
*
* @param string $property
* The property to return.
*
* @return mixed
* The value.
*/
public function get($property);
/**
* Sets the value for the given property.
*
* @param string $property
* The name of the property to set.
* @param mixed $value
* The value to set.
*/
public function set($property, $value);
/**
* Returns the machine name of the permission.
*
* @return string
* The permission machine name.
*/
public function getName();
/**
* Sets the machine name of the permission.
*
* @param string $name
* The machine name.
*
* @return $this
*/
public function setName($name);
/**
* Returns the human readable permission title.
*
* @return string
* The human readable permission title.
*/
public function getTitle();
/**
* Sets the human readable permission title.
*
* @param string $title
* The human readable title.
*
* @return $this
*/
public function setTitle($title);
/**
* Returns the description.
*
* @return string
* The description.
*/
public function getDescription();
/**
* Sets the description.
*
* @param string $description
* The machine description.
*
* @return $this
*/
public function setDescription($description);
/**
* Returns the default roles.
*
* @return array
* The default roles.
*/
public function getDefaultRoles();
/**
* Sets the default roles.
*
* @param array $default_roles
* The default roles.
*
* @return $this
*/
public function setDefaultRoles(array $default_roles);
/**
* Returns whether or not access is restricted.
*
* @return bool
* Whether or not access is restricted.
*/
public function getRestrictAccess();
/**
* Sets the access restriction.
*
* @param bool $access
* Whether or not this permission is security sensitive and should only be
* granted to administrators.
*
* @return $this
*/
public function setRestrictAccess($access);
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
PermissionInterface:: |
public | function | Returns the value for the given property. | 1 |
PermissionInterface:: |
public | function | Returns the default roles. | 1 |
PermissionInterface:: |
public | function | Returns the description. | 1 |
PermissionInterface:: |
public | function | Returns the machine name of the permission. | 1 |
PermissionInterface:: |
public | function | Returns whether or not access is restricted. | 1 |
PermissionInterface:: |
public | function | Returns the human readable permission title. | 1 |
PermissionInterface:: |
public | function | Sets the value for the given property. | 1 |
PermissionInterface:: |
public | function | Sets the default roles. | 1 |
PermissionInterface:: |
public | function | Sets the description. | 1 |
PermissionInterface:: |
public | function | Sets the machine name of the permission. | 1 |
PermissionInterface:: |
public | function | Sets the access restriction. | 1 |
PermissionInterface:: |
public | function | Sets the human readable permission title. | 1 |