HandlersLocator
in package
implements
HandlersLocatorInterface
Maps a message to a list of handlers.
Tags
Table of Contents
Interfaces
- HandlersLocatorInterface
- Maps a message to a list of handlers.
Properties
- $handlers : array<string|int, mixed>
Methods
- __construct() : mixed
- getHandlers() : iterable<int, HandlerDescriptor>
- Returns the handlers for the given message name.
- shouldHandle() : bool
Properties
$handlers
private
array<string|int, mixed>
$handlers
Methods
__construct()
public
__construct(array<string|int, array<string|int, HandlerDescriptor>>|array<string|int, array<string|int, callable>> $handlers) : mixed
Parameters
- $handlers : array<string|int, array<string|int, HandlerDescriptor>>|array<string|int, array<string|int, callable>>
getHandlers()
Returns the handlers for the given message name.
public
getHandlers(Envelope $envelope) : iterable<int, HandlerDescriptor>
Parameters
- $envelope : Envelope
Return values
iterable<int, HandlerDescriptor>shouldHandle()
private
shouldHandle(Envelope $envelope, HandlerDescriptor $handlerDescriptor) : bool
Parameters
- $envelope : Envelope
- $handlerDescriptor : HandlerDescriptor