Class: IronMQ::ResponseBase
- Inherits:
-
Object
- Object
- IronMQ::ResponseBase
- Defined in:
- lib/iron_mq/messages.rb
Direct Known Subclasses
Instance Method Summary collapse
- #[](key) ⇒ Object
- #id ⇒ Object
-
#initialize(res) ⇒ ResponseBase
constructor
A new instance of ResponseBase.
- #msg ⇒ Object
- #raw ⇒ Object
Constructor Details
#initialize(res) ⇒ ResponseBase
Returns a new instance of ResponseBase.
77 78 79 |
# File 'lib/iron_mq/messages.rb', line 77 def initialize(res) @data = res end |
Instance Method Details
#[](key) ⇒ Object
85 86 87 |
# File 'lib/iron_mq/messages.rb', line 85 def [](key) raw[key] end |
#id ⇒ Object
89 90 91 |
# File 'lib/iron_mq/messages.rb', line 89 def id raw["id"] end |
#msg ⇒ Object
93 94 95 |
# File 'lib/iron_mq/messages.rb', line 93 def msg raw["msg"] end |
#raw ⇒ Object
81 82 83 |
# File 'lib/iron_mq/messages.rb', line 81 def raw @data end |