Class: AMQ::Protocol::Basic::GetEmpty

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

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Method

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

Constructor Details

#initialize(cluster_id) ⇒ GetEmpty

Returns a new instance of GetEmpty.



1865
1866
1867
# File 'lib/amq/protocol/client.rb', line 1865

def initialize(cluster_id)
  @cluster_id = cluster_id
end

Instance Attribute Details

#cluster_idObject (readonly)

Returns the value of attribute cluster_id.



1864
1865
1866
# File 'lib/amq/protocol/client.rb', line 1864

def cluster_id
  @cluster_id
end

Class Method Details

.decode(data) ⇒ Object

Returns:



1855
1856
1857
1858
1859
1860
1861
1862
# File 'lib/amq/protocol/client.rb', line 1855

def self.decode(data)
  offset = 0
  length = data[offset, 1].unpack(PACK_CHAR).first
  offset += 1
  cluster_id = data[offset, length]
  offset += length
  self.new(cluster_id)
end

.has_content?Boolean

Returns:

  • (Boolean)


1869
1870
1871
# File 'lib/amq/protocol/client.rb', line 1869

def self.has_content?
  false
end