Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. PluginID.php

class PluginID

Same name in this branch
  1. 11.1.x core/lib/Drupal/Component/Annotation/PluginID.php \Drupal\Component\Annotation\PluginID

Defines a Plugin attribute object that just contains an ID.

Hierarchy

  • class \Drupal\Component\Plugin\Attribute\AttributeBase implements \Drupal\Component\Plugin\Attribute\AttributeInterface
    • class \Drupal\Component\Plugin\Attribute\PluginID extends \Drupal\Component\Plugin\Attribute\AttributeBase

Expanded class hierarchy of PluginID

9 files declare their use of PluginID
MigratePluginManager.php in core/modules/migrate/src/Plugin/MigratePluginManager.php
NullIdMap.php in core/modules/migrate/src/Plugin/migrate/id_map/NullIdMap.php
Sql.php in core/modules/migrate/src/Plugin/migrate/id_map/Sql.php
ViewsArea.php in core/modules/views/src/Attribute/ViewsArea.php
ViewsField.php in core/modules/views/src/Attribute/ViewsField.php

... See full list

File

core/lib/Drupal/Component/Plugin/Attribute/PluginID.php, line 8

Namespace

Drupal\Component\Plugin\Attribute
View source
class PluginID extends AttributeBase {
    
    /**
     * {@inheritdoc}
     */
    public function get() : array {
        return [
            'id' => $this->getId(),
            'class' => $this->getClass(),
            'provider' => $this->getProvider(),
        ];
    }

}

Members

Title Sort descending Modifiers Object type Summary Overriden Title Overrides
AttributeBase::$class protected property The class used for this attribute class.
AttributeBase::$provider protected property The provider of the attribute class.
AttributeBase::getClass public function Gets the class of the attribute class. Overrides AttributeInterface::getClass 1
AttributeBase::getId public function Gets the unique ID for this attribute class. Overrides AttributeInterface::getId
AttributeBase::getProvider public function Gets the name of the provider of the attribute class. Overrides AttributeInterface::getProvider
AttributeBase::setClass public function Sets the class of the attributed class. Overrides AttributeInterface::setClass 1
AttributeBase::setProvider public function Sets the name of the provider of the attribute class. Overrides AttributeInterface::setProvider
AttributeBase::__construct public function 2
PluginID::get public function Gets the value of an attribute. Overrides AttributeBase::get

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal