Class: AMQ::Protocol::Basic::ConsumeOk
- Defined in:
- lib/amq/protocol/client.rb
Instance Attribute Summary collapse
-
#consumer_tag ⇒ Object
readonly
Returns the value of attribute consumer_tag.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(consumer_tag) ⇒ ConsumeOk
constructor
A new instance of ConsumeOk.
Methods inherited from Method
encode_body, index, inherited, instantiate, method_id, methods, name, split_headers
Constructor Details
#initialize(consumer_tag) ⇒ ConsumeOk
Returns a new instance of ConsumeOk.
1701 1702 1703 |
# File 'lib/amq/protocol/client.rb', line 1701 def initialize(consumer_tag) @consumer_tag = consumer_tag end |
Instance Attribute Details
#consumer_tag ⇒ Object (readonly)
Returns the value of attribute consumer_tag.
1700 1701 1702 |
# File 'lib/amq/protocol/client.rb', line 1700 def consumer_tag @consumer_tag end |
Class Method Details
.decode(data) ⇒ Object
1691 1692 1693 1694 1695 1696 1697 1698 |
# File 'lib/amq/protocol/client.rb', line 1691 def self.decode(data) offset = offset = 0 # self-assigning offset to eliminate "assigned but unused variable" warning even if offset is not used in this method length = data[offset, 1].unpack(PACK_CHAR).first offset += 1 consumer_tag = data[offset, length] offset += length self.new(consumer_tag) end |
.has_content? ⇒ Boolean
1705 1706 1707 |
# File 'lib/amq/protocol/client.rb', line 1705 def self.has_content? false end |