You are here

class AccessControlHierarchy in Workbench Access 8

Defines a hierarchical access control annotation object.

Plugin Namespace: Plugin\AccessControlHierarchy.

For a working example, see \Drupal\workbench_access\Plugin\AccessControlHierarchy\Taxonomy.

Modules should use Drupal\workbench_access\AccessControlHierarchyBase as a basis for new implementations.

Hierarchy

Expanded class hierarchy of AccessControlHierarchy

See also

Plugin API

4 classes are annotated with AccessControlHierarchy
DerivedAccessControlHierarchy in tests/modules/workbench_access_test/src/Plugin/AccessControlHierarchy/DerivedAccessControlHierarchy.php
Defines a hierarchy based on an entity hierarchy field.
FilterAccess in tests/modules/workbench_access_filter_test/src/Plugin/AccessControlHierarchy/FilterAccess.php
Defines a test hierarchy for the sake of config entity access.
Menu in src/Plugin/AccessControlHierarchy/Menu.php
Defines a hierarchy based on a Menu.
Taxonomy in src/Plugin/AccessControlHierarchy/Taxonomy.php
Defines a hierarchy based on a Vocabulary.

File

src/Annotation/AccessControlHierarchy.php, line 22

Namespace

Drupal\workbench_access\Annotation
View source
class AccessControlHierarchy extends Plugin {

  /**
   * The plugin ID.
   *
   * @var string
   */
  public $id;

  /**
   * The module required by the plugin.
   *
   * @var string
   */
  public $module;

  /**
   * The human-readable name of the hierarchy system.
   *
   * @var \Drupal\Core\Annotation\Translation
   *
   * @ingroup plugin_translatable
   */
  public $label;

  /**
   * The entity that defines an access control item. (Optional)
   *
   * @var string
   */
  public $entity;

  /**
   * A brief description of the hierarchy source.
   *
   * This will be shown when adding or configuring Workbench Access.
   *
   * @var \Drupal\Core\Annotation\Translation
   *
   * @ingroup plugin_translatable
   */
  public $description = '';

}

Members

Namesort descending Modifiers Type Description Overrides
AccessControlHierarchy::$description public property A brief description of the hierarchy source.
AccessControlHierarchy::$entity public property The entity that defines an access control item. (Optional)
AccessControlHierarchy::$id public property The plugin ID.
AccessControlHierarchy::$label public property The human-readable name of the hierarchy system.
AccessControlHierarchy::$module public property The module required by the plugin.
Plugin::$definition protected property The plugin definition read from the class annotation. 1
Plugin::get public function Gets the value of an annotation. Overrides AnnotationInterface::get 5
Plugin::getClass public function Gets the class of the annotated class. Overrides AnnotationInterface::getClass
Plugin::getId public function Gets the unique ID for this annotated class. Overrides AnnotationInterface::getId
Plugin::getProvider public function Gets the name of the provider of the annotated class. Overrides AnnotationInterface::getProvider
Plugin::parse protected function Parses an annotation into its definition.
Plugin::setClass public function Sets the class of the annotated class. Overrides AnnotationInterface::setClass
Plugin::setProvider public function Sets the name of the provider of the annotated class. Overrides AnnotationInterface::setProvider
Plugin::__construct public function Constructs a Plugin object. 2