class EntityTypeAlterEvent in Hook Event Dispatcher 3.x
Same name and namespace in other branches
- 8.2 modules/core_event_dispatcher/src/Event/Entity/EntityTypeAlterEvent.php \Drupal\core_event_dispatcher\Event\Entity\EntityTypeAlterEvent
Class EntityTypeBuildEvent.
Hierarchy
- class \Drupal\core_event_dispatcher\Event\Entity\EntityTypeAlterEvent extends \Symfony\Component\EventDispatcher\Event implements EventInterface
Expanded class hierarchy of EntityTypeAlterEvent
2 files declare their use of EntityTypeAlterEvent
- core_event_dispatcher.module in modules/
core_event_dispatcher/ core_event_dispatcher.module - Core event dispatcher submodule.
- EntityTypeAlterEventTest.php in modules/
core_event_dispatcher/ tests/ src/ Unit/ Entity/ EntityTypeAlterEventTest.php
File
- modules/
core_event_dispatcher/ src/ Event/ Entity/ EntityTypeAlterEvent.php, line 12
Namespace
Drupal\core_event_dispatcher\Event\EntityView source
class EntityTypeAlterEvent extends Event implements EventInterface {
/**
* Field info.
*
* @var array
*/
private $entityTypes;
/**
* EntityTypeBuildEvent constructor.
*
* @param array $entityTypes
* Extra types info.
*/
public function __construct(array &$entityTypes) {
$this->entityTypes =& $entityTypes;
}
/**
* {@inheritdoc}
*/
public function getDispatcherType() : string {
return HookEventDispatcherInterface::ENTITY_TYPE_ALTER;
}
/**
* Get the entity types.
*
* @return \Drupal\Core\Entity\EntityTypeInterface[]
* Entity types info.
*/
public function &getEntityTypes() : array {
return $this->entityTypes;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
EntityTypeAlterEvent:: |
private | property | Field info. | |
EntityTypeAlterEvent:: |
public | function |
Get the dispatcher type. Overrides EventInterface:: |
|
EntityTypeAlterEvent:: |
public | function | Get the entity types. | |
EntityTypeAlterEvent:: |
public | function | EntityTypeBuildEvent constructor. |