\Drupflare\Anachron\Drupal\Cache LegacyCacheSubscriber

Puts the collected legacy cache metadata on the response, ahead of the page caches.

Summary

Methods
Properties
Constants
__construct
getSubscribedEvents
onRequest
onResponse
onTerminate
No public properties found
No public constants found
No protected methods found
No protected properties found
No protected constants found
No private methods found
collector
No private constants found

Properties

$collector

$collector : \Drupflare\Anachron\Drupal\Cache\LegacyCacheCollector

Type

LegacyCacheCollector

Methods

__construct()

__construct(\Drupflare\Anachron\Drupal\Cache\LegacyCacheCollector  $collector) : mixed

Parameters

\Drupflare\Anachron\Drupal\Cache\LegacyCacheCollector $collector

Returns

mixed —

getSubscribedEvents()

getSubscribedEvents() : array

Subscribes to the request, response and terminate events.

Returns

array —

onRequest()

onRequest(\Symfony\Component\HttpKernel\Event\RequestEvent  $event) : void

Starts a request with nothing collected.

Parameters

\Symfony\Component\HttpKernel\Event\RequestEvent $event

Returns

void —

onResponse()

onResponse(\Symfony\Component\HttpKernel\Event\ResponseEvent  $event) : void

Puts the collected metadata on the response.

Parameters

\Symfony\Component\HttpKernel\Event\ResponseEvent $event

Returns

void —

onTerminate()

onTerminate(\Symfony\Component\HttpKernel\Event\TerminateEvent  $event) : void

Clears the collector after the response was sent.

Parameters

\Symfony\Component\HttpKernel\Event\TerminateEvent $event

Returns

void —