function Plugin::__construct

Same name in this branch
  1. 10 core/lib/Drupal/Component/Annotation/Plugin.php \Drupal\Component\Annotation\Plugin::__construct()
Same name and namespace in other branches
  1. 9 core/lib/Drupal/Component/Annotation/Plugin.php \Drupal\Component\Annotation\Plugin::__construct()
  2. 8.9.x core/lib/Drupal/Component/Annotation/Plugin.php \Drupal\Component\Annotation\Plugin::__construct()
  3. 11.x core/lib/Drupal/Component/Annotation/Plugin.php \Drupal\Component\Annotation\Plugin::__construct()
  4. 11.x core/lib/Drupal/Component/Plugin/Attribute/Plugin.php \Drupal\Component\Plugin\Attribute\Plugin::__construct()

Constructs a plugin attribute object.

Parameters

string $id: The attribute class ID.

class-string|null $deriver: (optional) The deriver class.

Overrides AttributeBase::__construct

20 methods override Plugin::__construct()
Action::__construct in core/lib/Drupal/Core/Action/Attribute/Action.php
Constructs an Action attribute.
Archiver::__construct in core/lib/Drupal/Core/Archiver/Attribute/Archiver.php
Constructs an archiver plugin attribute object.
Block::__construct in core/lib/Drupal/Core/Block/Attribute/Block.php
Constructs a Block attribute.
Condition::__construct in core/lib/Drupal/Core/Condition/Attribute/Condition.php
Constructs a Condition attribute.
Constraint::__construct in core/lib/Drupal/Core/Validation/Attribute/Constraint.php
Constructs a Constraint attribute.

... See full list

File

core/lib/Drupal/Component/Plugin/Attribute/Plugin.php, line 25

Class

Plugin
Defines a Plugin attribute object.

Namespace

Drupal\Component\Plugin\Attribute

Code

public function __construct(string $id, ?string $deriver = NULL) {
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.