| 1 | <?php |
||
| 30 | final class AmqpBindingsProvider |
||
| 31 | { |
||
| 32 | /** |
||
| 33 | * @var \Closure[] array of closures, that bind routing keys to a right queue. |
||
| 34 | * Expected closure signature is: |
||
| 35 | * |
||
| 36 | * ```php |
||
| 37 | * function (PhpAmqpLib\Channel\AMQPChannel $channel): void { |
||
| 38 | * // Bind here, e.g. |
||
| 39 | * $channel->queue_declare('recon.queue', false, true, false, false); |
||
| 40 | * $channel->exchange_declare('dbms.updates', 'topic', false, true, true, false, false); |
||
| 41 | * $channel->queue_bind('recon.queue', 'dbms.updates', 'bot.dns.*'); |
||
| 42 | * } |
||
| 43 | * ``` |
||
| 44 | */ |
||
| 45 | public $bindings = []; |
||
| 46 | |||
| 47 | public function bind(AMQPChannel $channel): void |
||
| 53 | } |
||
| 54 |