Class: AMQ::Protocol::Queue::Purge

Inherits:
Method
  • Object
show all
Defined in:
lib/amq/protocol/client.rb

Class Method Summary collapse

Methods inherited from Method

encode_body, index, inherited, instantiate, method_id, methods, name, split_headers

Class Method Details

.encode(channel, queue, nowait) ⇒ Object

“ticket = 0”, “queue = EMPTY_STRING”, “nowait = false”

Returns:



1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
# File 'lib/amq/protocol/client.rb', line 1121

def self.encode(channel, queue, nowait)
  ticket = 0
  buffer = ""
  buffer << @packed_indexes
  buffer << [ticket].pack(PACK_UINT16)
  buffer << queue.bytesize.chr
  buffer << queue
  bit_buffer = 0
  bit_buffer = bit_buffer | (1 << 0) if nowait
  buffer << [bit_buffer].pack(PACK_CHAR)
  MethodFrame.new(buffer, channel)
end

.has_content?Boolean

Returns:

  • (Boolean)


1115
1116
1117
# File 'lib/amq/protocol/client.rb', line 1115

def self.has_content?
  false
end