interface PluginDefinitionInterface in Drupal 8
Same name and namespace in other branches
- 9 core/lib/Drupal/Component/Plugin/Definition/PluginDefinitionInterface.php \Drupal\Component\Plugin\Definition\PluginDefinitionInterface
Defines a plugin definition.
Object-based plugin definitions MUST implement this interface.
Hierarchy
- interface \Drupal\Component\Plugin\Definition\PluginDefinitionInterface
Expanded class hierarchy of PluginDefinitionInterface
All classes that implement PluginDefinitionInterface
7 files declare their use of PluginDefinitionInterface
- DefaultFactory.php in core/
lib/ Drupal/ Component/ Plugin/ Factory/ DefaultFactory.php - DefaultFactoryTest.php in core/
tests/ Drupal/ Tests/ Component/ Plugin/ DefaultFactoryTest.php - DefaultPluginManager.php in core/
lib/ Drupal/ Core/ Plugin/ DefaultPluginManager.php - EntityTypeInterface.php in core/
lib/ Drupal/ Core/ Entity/ EntityTypeInterface.php - LayoutDefinition.php in core/
lib/ Drupal/ Core/ Layout/ LayoutDefinition.php
File
- core/
lib/ Drupal/ Component/ Plugin/ Definition/ PluginDefinitionInterface.php, line 12
Namespace
Drupal\Component\Plugin\DefinitionView source
interface PluginDefinitionInterface {
/**
* Gets the unique identifier of the plugin.
*
* @return string
* The unique identifier of the plugin.
*/
public function id();
/**
* Sets the class.
*
* @param string $class
* A fully qualified class name.
*
* @return static
*
* @throws \InvalidArgumentException
* If the class is invalid.
*/
public function setClass($class);
/**
* Gets the class.
*
* @return string
* A fully qualified class name.
*/
public function getClass();
/**
* Gets the plugin provider.
*
* The provider is the name of the module that provides the plugin, or "core',
* or "component".
*
* @return string
* The provider.
*/
public function getProvider();
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
PluginDefinitionInterface:: |
public | function | Gets the class. | 1 |
PluginDefinitionInterface:: |
public | function | Gets the plugin provider. | 1 |
PluginDefinitionInterface:: |
public | function | Gets the unique identifier of the plugin. | 1 |
PluginDefinitionInterface:: |
public | function | Sets the class. | 1 |