Symfony2 API
Class

Symfony\Component\HttpKernel\EventListener\EsiListener

class EsiListener extends SurrogateListener

EsiListener adds a Surrogate-Control HTTP header when the Response needs to be parsed for ESI.

Methods

__construct(SurrogateInterface $surrogate = null)

Constructor.

from SurrogateListener
onKernelResponse(FilterResponseEvent $event)

Filters the Response.

from SurrogateListener
static array getSubscribedEvents()

Returns an array of event names this subscriber wants to listen to.

from SurrogateListener

Details

in SurrogateListener at line 33
public __construct(SurrogateInterface $surrogate = null)

Constructor.

Parameters

SurrogateInterface $surrogate An SurrogateInterface instance

in SurrogateListener at line 43
public onKernelResponse(FilterResponseEvent $event)

Filters the Response.

Parameters

FilterResponseEvent $event A FilterResponseEvent instance

in SurrogateListener at line 52
static public array getSubscribedEvents()

Returns an array of event names this subscriber wants to listen to.

The array keys are event names and the value can be:

For instance:

Return Value

array The event names to listen to