| 1 | <?php |
||
| 9 | class Queue extends Factory |
||
| 10 | { |
||
| 11 | /** |
||
| 12 | * Constructor - receive server adapter, adapter api authentication and http client details. |
||
| 13 | * Initialise the http client and make it available for use by the server adapter. |
||
| 14 | * |
||
| 15 | * @param QueueAdapterInterface $adapter |
||
| 16 | * @param HttpClientInterface $client |
||
| 17 | */ |
||
| 18 | public function __construct(QueueAdapterInterface $adapter, HttpClientInterface $client = null) |
||
| 22 | |||
| 23 | /** |
||
| 24 | * Receives the name of a queue and returns the number of jobs in that queue. |
||
| 25 | * |
||
| 26 | * @param string $queue |
||
| 27 | * @return integer |
||
| 28 | */ |
||
| 29 | public function count($queue) |
||
| 33 | |||
| 34 | /** |
||
| 35 | * Empty a named queue. |
||
| 36 | * |
||
| 37 | * @param string $queue |
||
| 38 | * @return void |
||
| 39 | */ |
||
| 40 | public function clear($queue) |
||
| 44 | } |
||
| 45 |