| 1 | <?php |
||
| 8 | abstract class AbstractQueue implements \Bernard\Queue |
||
| 9 | { |
||
| 10 | protected $closed; |
||
| 11 | protected $name; |
||
| 12 | |||
| 13 | /** |
||
| 14 | * @param string $name |
||
| 15 | */ |
||
| 16 | 55 | public function __construct($name) |
|
| 20 | |||
| 21 | /** |
||
| 22 | * {@inheritdoc} |
||
| 23 | */ |
||
| 24 | 13 | public function close() |
|
| 28 | |||
| 29 | /** |
||
| 30 | * By Default this is not implemented. For Memory queues it does not make sense. |
||
| 31 | * |
||
| 32 | * {@inheritdoc} |
||
| 33 | */ |
||
| 34 | 6 | public function acknowledge(Envelope $envelope) |
|
| 38 | |||
| 39 | /** |
||
| 40 | * @throws InvalidOperationException |
||
| 41 | */ |
||
| 42 | 44 | protected function errorIfClosed() |
|
| 48 | |||
| 49 | /** |
||
| 50 | * {@inheritdoc} |
||
| 51 | */ |
||
| 52 | 13 | public function __toString() |
|
| 56 | } |
||
| 57 |