Skip to content

Commit 0daf2e8

Browse files
committed
Add empty method 'size'. To be implemented
1 parent e8cd21f commit 0daf2e8

File tree

2 files changed

+14
-3
lines changed

2 files changed

+14
-3
lines changed

composer.json

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,6 @@
1515
"illuminate/queue": "5.3.*",
1616
"php-amqplib/php-amqplib": "2.6.*"
1717
},
18-
"require-dev": {
19-
"laravel/framework": "5.3.*"
20-
},
2118
"autoload": {
2219
"psr-0": {
2320
"VladimirYuldashev\\LaravelQueueRabbitMQ": "src/"

src/VladimirYuldashev/LaravelQueueRabbitMQ/Queue/RabbitMQQueue.php

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,17 @@ public function __construct(AMQPStreamConnection $amqpConnection, $config)
5454
$this->channel = $this->getChannel();
5555
}
5656

57+
/**
58+
* Get the size of the queue.
59+
*
60+
* @param string $queue
61+
* @return int
62+
*/
63+
public function size($queue = null)
64+
{
65+
// TODO: Implement size() method.
66+
}
67+
5768
/**
5869
* Push a new job onto the queue.
5970
*
@@ -143,6 +154,8 @@ public function pop($queue = null)
143154
if ($message instanceof AMQPMessage) {
144155
return new RabbitMQJob($this->container, $this, $this->channel, $queue, $message);
145156
}
157+
158+
return null;
146159
}
147160

148161
/**
@@ -278,4 +291,5 @@ public function getCorrelationId()
278291
{
279292
return $this->correlationId ?: uniqid();
280293
}
294+
281295
}

0 commit comments

Comments
 (0)