RegisterListenersPass

class RegisterListenersPass implements CompilerPassInterface

Compiler pass to register tagged services for an event dispatcher.

Methods

__construct(string $dispatcherService = 'event_dispatcher', string $listenerTag = 'kernel.event_listener', string $subscriberTag = 'kernel.event_subscriber')
setHotPathEvents(array $hotPathEvents, $tagName = 'container.hot_path')
process(ContainerBuilder $container)

You can modify the container here before it is dumped to PHP code.

Details

__construct(string $dispatcherService = 'event_dispatcher', string $listenerTag = 'kernel.event_listener', string $subscriberTag = 'kernel.event_subscriber')

Parameters

string $dispatcherService
string $listenerTag
string $subscriberTag

setHotPathEvents(array $hotPathEvents, $tagName = 'container.hot_path')

Parameters

array $hotPathEvents
$tagName

process(ContainerBuilder $container)

You can modify the container here before it is dumped to PHP code.

Parameters

ContainerBuilder $container