class ReferenceablePluginTypesEvent in Commerce Core 8.2
Defines the referenceable plugin types event.
Hierarchy
- class \Drupal\commerce\EventBase extends \Drupal\Component\EventDispatcher\Event
- class \Drupal\commerce\Event\ReferenceablePluginTypesEvent
Expanded class hierarchy of ReferenceablePluginTypesEvent
See also
\Drupal\commerce\Event\CommerceEvents
2 files declare their use of ReferenceablePluginTypesEvent
- PluginItemDeriver.php in src/
Plugin/ Field/ FieldType/ PluginItemDeriver.php - ReferenceablePluginTypesSubscriber.php in tests/
modules/ commerce_test/ src/ EventSubscriber/ ReferenceablePluginTypesSubscriber.php
File
- src/
Event/ ReferenceablePluginTypesEvent.php, line 12
Namespace
Drupal\commerce\EventView source
class ReferenceablePluginTypesEvent extends EventBase {
/**
* The plugin types, in the id => label format.
*
* @var array
*/
protected $pluginTypes;
/**
* Constructs a new ReferenceablePluginTypesEvent object.
*
* @param array $plugin_types
* The plugin types, in the id => label format.
*/
public function __construct(array $plugin_types) {
$this->pluginTypes = $plugin_types;
}
/**
* Gets the plugin types.
*
* @return array
* The plugin types, in the id => label format.
*/
public function getPluginTypes() {
return $this->pluginTypes;
}
/**
* Sets the plugin types.
*
* @param array $plugin_types
* The plugin types, in the id => label format.
*
* @return $this
*/
public function setPluginTypes(array $plugin_types) {
$this->pluginTypes = $plugin_types;
return $this;
}
}
Members
Name![]() |
Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ReferenceablePluginTypesEvent:: |
protected | property | The plugin types, in the id => label format. | |
ReferenceablePluginTypesEvent:: |
public | function | Gets the plugin types. | |
ReferenceablePluginTypesEvent:: |
public | function | Sets the plugin types. | |
ReferenceablePluginTypesEvent:: |
public | function | Constructs a new ReferenceablePluginTypesEvent object. |