Skip to content

StoppableEvent

An Event whose propagation a listener can halt.

Once StoppableEvent::stopPropagation() is called, EventDispatcher::dispatch() stops invoking further listeners — the standard PSR-14 stoppable contract.

abstract class StoppableEvent extends Event implements StoppableEventInterface

ExtendsEvent
ImplementsStoppableEventInterface
SourceEvent/StoppableEvent.php
MethodDescription
isPropagationStopped(): boolWhether a listener has already called StoppableEvent::stopPropagation() on this event.
stopPropagation(): voidHalts propagation so the dispatcher invokes no further listeners for this event.

public function isPropagationStopped(): bool

Whether a listener has already called StoppableEvent::stopPropagation() on this event.

Returns bool

public function stopPropagation(): void

Halts propagation so the dispatcher invokes no further listeners for this event.