PluginID.php

Contains Drupal\Component\Annotation\PluginID.

Namespace

Drupal\Component\Annotation

File

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

/**
 * @file
 * Contains Drupal\Component\Annotation\PluginID.
 */
namespace Drupal\Component\Annotation;


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

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

  /**
   * Implements \Drupal\Core\Annotation\AnnotationInterface::get().
   */
  public function get() {
    return array(
      'id' => $this->value,
    );
  }

}

Classes

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