class Plugin3A in Service Container 7
Same name and namespace in other branches
- 7.2 modules/providers/service_container_annotation_discovery/tests/modules/service_container_annotation_discovery_test/src/Plugin/Plugin3/Plugin3A/Plugin3A.php \Drupal\service_container_annotation_discovery_test\Plugin\Plugin3\Plugin3A\Plugin3A
Class Plugin3A
@Plugin( id = "Plugin3A", label = "Label Plugin3A" )
@package Drupal\service_container_annotation_discovery_test\Plugin\Plugin3\Plugin3A
Hierarchy
- class \Drupal\Component\Plugin\PluginBase implements DerivativeInspectionInterface, PluginInspectionInterface
- class \Drupal\service_container_annotation_discovery_test\Plugin\Plugin3\Plugin3A\Plugin3A implements ContainerFactoryPluginInterface
Expanded class hierarchy of Plugin3A
1 string reference to 'Plugin3A'
- ServiceContainerAnnotationDiscoveryIntegrationTest::testDoctrinePlugin in modules/
providers/ service_container_annotation_discovery/ lib/ Drupal/ service_container_annotation_discovery/ Tests/ ServiceContainerAnnotationDiscoveryIntegrationTest.php - Tests if plugins with annotations are available as services.
File
- modules/
providers/ service_container_annotation_discovery/ tests/ modules/ service_container_annotation_discovery_test/ src/ Plugin/ Plugin3/ Plugin3A/ Plugin3A.php, line 20
Namespace
Drupal\service_container_annotation_discovery_test\Plugin\Plugin3\Plugin3AView source
class Plugin3A extends PluginBase implements ContainerFactoryPluginInterface {
protected $data;
/**
* @inheritdoc
*/
public static function create(ContainerInterface $container, array $configuration, $plugin_id, $plugin_definition) {
return new static($configuration, $plugin_id, $plugin_definition, 'Hello world!');
}
public function __construct($configuration, $plugin_id, $plugin_definition, $data) {
parent::__construct($configuration, $plugin_id, $plugin_definition);
$this->data = $data;
}
public function getData() {
return $this->data;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
Plugin3A:: |
protected | property | ||
Plugin3A:: |
public static | function |
@inheritdoc Overrides ContainerFactoryPluginInterface:: |
|
Plugin3A:: |
public | function | ||
Plugin3A:: |
public | function |
Constructs a Drupal\Component\Plugin\PluginBase object. Overrides PluginBase:: |
|
PluginBase:: |
protected | property | Configuration information passed into the plugin. | |
PluginBase:: |
protected | property | The plugin implementation definition. | |
PluginBase:: |
protected | property | The plugin_id. | |
PluginBase:: |
constant | A string which is used to separate base plugin IDs from the derivative ID. | ||
PluginBase:: |
public | function |
Gets the base_plugin_id of the plugin instance. Overrides DerivativeInspectionInterface:: |
|
PluginBase:: |
public | function |
Gets the derivative_id of the plugin instance. Overrides DerivativeInspectionInterface:: |
|
PluginBase:: |
public | function |
Gets the definition of the plugin implementation. Overrides PluginInspectionInterface:: |
|
PluginBase:: |
public | function |
Gets the plugin_id of the plugin instance. Overrides PluginInspectionInterface:: |