You are here

final class FieldPreprocessEventFactory in Hook Event Dispatcher 8

Class FieldPreprocessEventFactory.

Hierarchy

Expanded class hierarchy of FieldPreprocessEventFactory

1 string reference to 'FieldPreprocessEventFactory'
hook_event_dispatcher.services.yml in ./hook_event_dispatcher.services.yml
hook_event_dispatcher.services.yml
1 service uses FieldPreprocessEventFactory
preprocess_event.factory.field in ./hook_event_dispatcher.services.yml
Drupal\hook_event_dispatcher\Event\Preprocess\Factory\FieldPreprocessEventFactory

File

src/Event/Preprocess/Factory/FieldPreprocessEventFactory.php, line 11

Namespace

Drupal\hook_event_dispatcher\Event\Preprocess\Factory
View source
final class FieldPreprocessEventFactory implements PreprocessEventFactoryInterface {

  /**
   * {@inheritdoc}
   */
  public function createEvent(array &$variables) {
    return new FieldPreprocessEvent(new FieldEventVariables($variables));
  }

  /**
   * {@inheritdoc}
   */
  public function getEventHook() {
    return FieldPreprocessEvent::getHook();
  }

}

Members

Namesort descending Modifiers Type Description Overrides
FieldPreprocessEventFactory::createEvent public function Create the PreprocessEvent with the Variables object embedded. Overrides PreprocessEventFactoryInterface::createEvent
FieldPreprocessEventFactory::getEventHook public function Get the Event hook name. Overrides PreprocessEventFactoryInterface::getEventHook