You are here

CommentPreprocessEventFactory.php in Hook Event Dispatcher 8

File

src/Event/Preprocess/Factory/CommentPreprocessEventFactory.php
View source
<?php

namespace Drupal\hook_event_dispatcher\Event\Preprocess\Factory;

use Drupal\hook_event_dispatcher\Event\Preprocess\CommentPreprocessEvent;
use Drupal\hook_event_dispatcher\Event\Preprocess\Variables\CommentEventVariables;

/**
 * Class CommentPreprocessEventFactory.
 */
final class CommentPreprocessEventFactory implements PreprocessEventFactoryInterface {

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

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

}

Classes

Namesort descending Description
CommentPreprocessEventFactory Class CommentPreprocessEventFactory.