SendersLocator
in package
implements
SendersLocatorInterface
Maps a message to a list of senders.
Tags
Table of Contents
Interfaces
- SendersLocatorInterface
- Maps a message to a list of senders.
Properties
- $sendersLocator : mixed
- $sendersMap : array<string|int, mixed>
Methods
- __construct() : mixed
- getSenders() : iterable<string, SenderInterface>
- Gets the senders for the given message name.
Properties
$sendersLocator
private
mixed
$sendersLocator
$sendersMap
private
array<string|int, mixed>
$sendersMap
Methods
__construct()
public
__construct(array<string, array<int, string>> $sendersMap, ContainerInterface $sendersLocator) : mixed
Parameters
- $sendersMap : array<string, array<int, string>>
-
An array, keyed by "type", set to an array of sender aliases
- $sendersLocator : ContainerInterface
-
Locator of senders, keyed by sender alias
getSenders()
Gets the senders for the given message name.
public
getSenders(Envelope $envelope) : iterable<string, SenderInterface>
Parameters
- $envelope : Envelope
Return values
iterable<string, SenderInterface> —Indexed by sender alias if available