def get(self, queue, consumer=None, no_ack=True, ticket=None):
        '''
        Ask to fetch a single message from a queue.  If a consumer is supplied,
        the consumer will be called with either a Message argument, or None if
        there is no message in queue. If a synchronous transport, Message or
        None is returned.
        '''
        args = Writer()
        args.write_short(ticket or self.default_ticket).\
            write_shortstr(queue).\
            write_bit(no_ack)

        self._get_cb.append(consumer)
        self.send_frame(MethodFrame(self.channel_id, 60, 70, args))
        return self.channel.add_synchronous_cb(self._recv_get_response)
def get ( self , queue , consumer = None , no_ack = True , ticket = None ) : args = Writer ( ) args . write_short ( ticket or self . default_ticket ) . write_shortstr ( queue ) . write_bit ( no_ack ) self . _get_cb . append ( consumer ) self . send_frame ( MethodFrame ( self . channel_id , 60 , 70 , args ) ) return self . channel . add_synchronous_cb ( self . _recv_get_response )
Ask to fetch a single message from a queue.  If a consumer is supplied,
        the consumer will be called with either a Message argument, or None if
        there is no message in queue. If a synchronous transport, Message or
        None is returned.