class EntityBundleFieldInfoAlterEvent in Hook Event Dispatcher 3.x
Same name and namespace in other branches
- 8.2 modules/core_event_dispatcher/src/Event/Entity/EntityBundleFieldInfoAlterEvent.php \Drupal\core_event_dispatcher\Event\Entity\EntityBundleFieldInfoAlterEvent
Class EntityBundleFieldInfoAlterEvent.
Hierarchy
- class \Drupal\core_event_dispatcher\Event\Entity\EntityBundleFieldInfoAlterEvent extends \Symfony\Component\EventDispatcher\Event implements EventInterface
Expanded class hierarchy of EntityBundleFieldInfoAlterEvent
2 files declare their use of EntityBundleFieldInfoAlterEvent
- core_event_dispatcher.module in modules/
core_event_dispatcher/ core_event_dispatcher.module - Core event dispatcher submodule.
- EntityBundleFieldInfoAlterEventTest.php in modules/
core_event_dispatcher/ tests/ src/ Unit/ Entity/ EntityBundleFieldInfoAlterEventTest.php
File
- modules/
core_event_dispatcher/ src/ Event/ Entity/ EntityBundleFieldInfoAlterEvent.php, line 13
Namespace
Drupal\core_event_dispatcher\Event\EntityView source
class EntityBundleFieldInfoAlterEvent extends Event implements EventInterface {
/**
* Field info.
*
* @var array
*/
private $fields;
/**
* The entity type.
*
* @var \Drupal\Core\Entity\EntityTypeInterface
*/
private $entityType;
/**
* The bundle name.
*
* @var string
*/
private $bundle;
/**
* EntityExtraFieldInfoAlterEvent constructor.
*
* @param array $fields
* Extra field info.
* @param \Drupal\Core\Entity\EntityTypeInterface $entityType
* The entity type.
* @param string $bundle
* The bundle name.
*/
public function __construct(array &$fields, EntityTypeInterface $entityType, string $bundle) {
$this->fields =& $fields;
$this->entityType = $entityType;
$this->bundle = $bundle;
}
/**
* {@inheritdoc}
*/
public function getDispatcherType() : string {
return HookEventDispatcherInterface::ENTITY_BUNDLE_FIELD_INFO_ALTER;
}
/**
* Get the field info.
*
* @return array
* Extra field info.
*/
public function &getFields() : array {
return $this->fields;
}
/**
* Get the EntityType.
*
* @return \Drupal\Core\Entity\EntityTypeInterface
* The EntityType.
*/
public function getEntityType() : EntityTypeInterface {
return $this->entityType;
}
/**
* Gets the Bundle.
*
* @return string
* The Bundle.
*/
public function getBundle() : string {
return $this->bundle;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
EntityBundleFieldInfoAlterEvent:: |
private | property | The bundle name. | |
EntityBundleFieldInfoAlterEvent:: |
private | property | The entity type. | |
EntityBundleFieldInfoAlterEvent:: |
private | property | Field info. | |
EntityBundleFieldInfoAlterEvent:: |
public | function | Gets the Bundle. | |
EntityBundleFieldInfoAlterEvent:: |
public | function |
Get the dispatcher type. Overrides EventInterface:: |
|
EntityBundleFieldInfoAlterEvent:: |
public | function | Get the EntityType. | |
EntityBundleFieldInfoAlterEvent:: |
public | function | Get the field info. | |
EntityBundleFieldInfoAlterEvent:: |
public | function | EntityExtraFieldInfoAlterEvent constructor. |