public function get($queueName, array $options = [], callable $callback = null)
    {
        $noAck = array_key_exists('noAck', $options) ? $options['noAck'] : null;

        $outputFrame = Basic\BasicGetFrame::create(
            $queueName,
            $noAck
        );
        $outputFrame->frameChannelId = $this->id;
        $this->connection->command($outputFrame);

        if (is_callable($callback)) {
            $this->on(self::EVENT_DISPATCH_MESSAGE, $callback);
        }
    }
public function get($queueName, array $options = [], callable $callback = null)
    {
        $noAck = array_key_exists('noAck', $options) ? $options['noAck'] : null;

        $outputFrame = Basic\BasicGetFrame::create(
            $queueName,
            $noAck
        );
        $outputFrame->frameChannelId = $this->id;
        $this->connection->command($outputFrame);

        if (is_callable($callback)) {
            $this->on(self::EVENT_DISPATCH_MESSAGE, $callback);
        }
    }
public function get ( $ queueName , array $ options = [ ] , callable $ callback = null ) { $ noAck = array_key_exists ( 'noAck' , $ options ) ? $ options [ 'noAck' ] : null ; $ outputFrame = Basic \ BasicGetFrame :: create ( $ queueName , $ noAck ) ; $ outputFrame -> frameChannelId = $ this -> id ; $ this -> connection -> command ( $ outputFrame ) ; if ( is_callable ( $ callback ) ) { $ this -> on ( self :: EVENT_DISPATCH_MESSAGE , $ callback ) ; } }
get message from queue

@param string $queueName a queue name
@param array $options
@param callable|null $callback
@throws \InvalidArgumentException
@throws \PHPDaemon\Clients\AMQP\Driver\Protocol\Exception\AMQPProtocolException
get message from queue