Class: Carrot::AMQP::Frame::Method

Inherits:
Frame
  • Object
show all
Defined in:
lib/carrot/amqp/spec.rb,
lib/carrot/amqp/frame.rb

Instance Method Summary collapse

Constructor Details

#initialize(payload = nil, channel = 0) ⇒ Method

Returns a new instance of Method.



35
36
37
38
39
40
# File 'lib/carrot/amqp/frame.rb', line 35

def initialize payload = nil, channel = 0
  super
  unless @payload.is_a? Protocol::Class::Method or @payload.nil?
    @payload = Protocol.parse(@payload)
  end
end