You are here

class LogsHttpEventSubscriber in Logs HTTP 8

Event subscribed for Logs http.

Hierarchy

  • class \Drupal\logs_http\EventSubscriber\LogsHttpEventSubscriber implements \Symfony\Component\EventDispatcher\EventSubscriberInterface

Expanded class hierarchy of LogsHttpEventSubscriber

1 string reference to 'LogsHttpEventSubscriber'
logs_http.services.yml in ./logs_http.services.yml
logs_http.services.yml
1 service uses LogsHttpEventSubscriber
logs_http.logs_http_subscriber in ./logs_http.services.yml
Drupal\logs_http\EventSubscriber\LogsHttpEventSubscriber

File

src/EventSubscriber/LogsHttpEventSubscriber.php, line 12

Namespace

Drupal\logs_http\EventSubscriber
View source
class LogsHttpEventSubscriber implements EventSubscriberInterface {

  /**
   * Initializes Logs http module requirements.
   *
   * @param \Symfony\Component\HttpKernel\Event\GetResponseEvent $event
   *   The event to process.
   */
  public function onRequest(GetResponseEvent $event) {
    drupal_register_shutdown_function('logs_http_shutdown');
  }

  /**
   * Implements EventSubscriberInterface::getSubscribedEvents().
   *
   * @return array
   *   An array of event listener definitions.
   */
  public static function getSubscribedEvents() {

    // Setting high priority for this subscription in order to execute it soon
    // enough.
    $events[KernelEvents::REQUEST][] = [
      'onRequest',
      1000,
    ];
    return $events;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
LogsHttpEventSubscriber::getSubscribedEvents public static function Implements EventSubscriberInterface::getSubscribedEvents().
LogsHttpEventSubscriber::onRequest public function Initializes Logs http module requirements.