You are here

class EntityExtraFieldInfoAlterEvent in Hook Event Dispatcher 3.x

Same name and namespace in other branches
  1. 8.2 modules/core_event_dispatcher/src/Event/Entity/EntityExtraFieldInfoAlterEvent.php \Drupal\core_event_dispatcher\Event\Entity\EntityExtraFieldInfoAlterEvent

Class EntityExtraFieldInfoAlterEvent.

Hierarchy

Expanded class hierarchy of EntityExtraFieldInfoAlterEvent

3 files declare their use of EntityExtraFieldInfoAlterEvent
core_event_dispatcher.module in modules/core_event_dispatcher/core_event_dispatcher.module
Core event dispatcher submodule.
EntityExtraEventTest.php in modules/core_event_dispatcher/tests/src/Unit/Entity/EntityExtraEventTest.php
ExampleEntityExtraFieldInfoSubscribers.php in examples/ExampleEntityExtraFieldInfoSubscribers.php

File

modules/core_event_dispatcher/src/Event/Entity/EntityExtraFieldInfoAlterEvent.php, line 12

Namespace

Drupal\core_event_dispatcher\Event\Entity
View source
class EntityExtraFieldInfoAlterEvent extends Event implements EventInterface {

  /**
   * Field info.
   *
   * @var array
   */
  private $fieldInfo;

  /**
   * EntityExtraFieldInfoAlterEvent constructor.
   *
   * @param array $fieldInfo
   *   Extra field info.
   */
  public function __construct(array &$fieldInfo) {
    $this->fieldInfo =& $fieldInfo;
  }

  /**
   * Get the dispatcher type.
   *
   * @return string
   *   The dispatcher type.
   */
  public function getDispatcherType() : string {
    return HookEventDispatcherInterface::ENTITY_EXTRA_FIELD_INFO_ALTER;
  }

  /**
   * Get the field info.
   *
   * @return array
   *   Extra field info.
   */
  public function &getFieldInfo() : array {
    return $this->fieldInfo;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
EntityExtraFieldInfoAlterEvent::$fieldInfo private property Field info.
EntityExtraFieldInfoAlterEvent::getDispatcherType public function Get the dispatcher type. Overrides EventInterface::getDispatcherType
EntityExtraFieldInfoAlterEvent::getFieldInfo public function Get the field info.
EntityExtraFieldInfoAlterEvent::__construct public function EntityExtraFieldInfoAlterEvent constructor.