Class: GorgonAMQ::Protocol::Basic::GetEmpty

Inherits:
Method
  • Object
show all
Defined in:
lib/gorgon_amq-protocol/lib/gorgon_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.



1920
1921
1922
# File 'lib/gorgon_amq-protocol/lib/gorgon_amq/protocol/client.rb', line 1920

def initialize(cluster_id)
  @cluster_id = cluster_id
end

Instance Attribute Details

#cluster_idObject (readonly)

Returns the value of attribute cluster_id.



1919
1920
1921
# File 'lib/gorgon_amq-protocol/lib/gorgon_amq/protocol/client.rb', line 1919

def cluster_id
  @cluster_id
end

Class Method Details

.decode(data) ⇒ Object

Returns:



1910
1911
1912
1913
1914
1915
1916
1917
# File 'lib/gorgon_amq-protocol/lib/gorgon_amq/protocol/client.rb', line 1910

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)


1924
1925
1926
# File 'lib/gorgon_amq-protocol/lib/gorgon_amq/protocol/client.rb', line 1924

def self.has_content?
  false
end