1. 8.5.x core/lib/Drupal/Component/Annotation/PluginID.php
  2. 8.0.x core/lib/Drupal/Component/Annotation/PluginID.php
  3. 8.1.x core/lib/Drupal/Component/Annotation/PluginID.php
  4. 8.2.x core/lib/Drupal/Component/Annotation/PluginID.php
  5. 8.3.x core/lib/Drupal/Component/Annotation/PluginID.php
  6. 8.4.x core/lib/Drupal/Component/Annotation/PluginID.php
  7. 8.6.x core/lib/Drupal/Component/Annotation/PluginID.php

Namespace

Drupal\Component\Annotation

File

core/lib/Drupal/Component/Annotation/PluginID.php
View source
<?php

namespace Drupal\Component\Annotation;


/**
 * Defines a Plugin annotation object that just contains an ID.
 *
 * @Annotation
 */
class PluginID extends AnnotationBase {

  /**
   * The plugin ID.
   *
   * When an annotation is given no key, 'value' is assumed by Doctrine.
   *
   * @var string
   */
  public $value;

  /**
   * {@inheritdoc}
   */
  public function get() {
    return array(
      'id' => $this->value,
      'class' => $this->class,
      'provider' => $this->provider,
    );
  }

  /**
   * {@inheritdoc}
   */
  public function getId() {
    return $this->value;
  }

}

Classes

Namesort descending Description
PluginID Defines a Plugin annotation object that just contains an ID.