| 1 | <?php |
||
| 15 | class ExecutingSubscribeCommandQueue implements SubscribeCommandQueue |
||
| 16 | { |
||
| 17 | /** |
||
| 18 | * @var callable|null |
||
| 19 | */ |
||
| 20 | private $handler; |
||
| 21 | |||
| 22 | /** |
||
| 23 | * Publish command to queue. |
||
| 24 | * |
||
| 25 | * @param Command $command |
||
| 26 | * |
||
| 27 | * @return bool |
||
| 28 | */ |
||
| 29 | 1 | public function publish(Command $command) |
|
| 38 | |||
| 39 | /** |
||
| 40 | * Subscribe on command queue. |
||
| 41 | * |
||
| 42 | * @param callable $handler |
||
| 43 | */ |
||
| 44 | 1 | public function subscribe(callable $handler) |
|
| 48 | } |
||
| 49 |