class AmqpReceiver implements ReceiverInterface
Symfony Messenger receiver to get messages from AMQP brokers using PHP's AMQP extension.
| __construct(DecoderInterface $decoder, Connection $connection) | ||
| void | receive(callable $handler) Receive some messages to the given handler. | |
| void | stop() Stop receiving some messages. |
| DecoderInterface | $decoder | |
| Connection | $connection |
Receive some messages to the given handler.
The handler will have, as argument, the received {@link \Symfony\Component\Messenger\Envelope} containing the message. Note that this envelope can be null if the timeout to receive something has expired.
| callable | $handler |
| void |
Stop receiving some messages.
| void |
© 2004–2017 Fabien Potencier
Licensed under the MIT License.
https://api.symfony.com/4.1/Symfony/Component/Messenger/Transport/AmqpExt/AmqpReceiver.html