| | <?php |
| |
|
| | namespace SimpleQueue; |
| |
|
| | use DateTime; |
| |
|
| | |
| | |
| | |
| | |
| | |
| | class Queue implements QueueAdapterInterface |
| | { |
| | |
| | |
| | |
| | protected $queueAdapter; |
| |
|
| | |
| | |
| | |
| | |
| | |
| | public function __construct(QueueAdapterInterface $queueAdapter) |
| | { |
| | $this->queueAdapter = $queueAdapter; |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | public function push(Job $job) |
| | { |
| | $this->queueAdapter->push($job); |
| | return $this; |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | public function schedule(Job $job, DateTime $dateTime) |
| | { |
| | $this->queueAdapter->schedule($job, $dateTime); |
| | return $this; |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | public function pull() |
| | { |
| | return $this->queueAdapter->pull(); |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | public function completed(Job $job) |
| | { |
| | $this->queueAdapter->completed($job); |
| | return $this; |
| | } |
| |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | public function failed(Job $job) |
| | { |
| | $this->queueAdapter->failed($job); |
| | return $this; |
| | } |
| | } |
| |
|