Class: IronMQ::ResponseBase
- Inherits:
-
Object
- Object
- IronMQ::ResponseBase
- Defined in:
- lib/iron_mq/response.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#raw ⇒ Object
readonly
Returns the value of attribute raw.
Instance Method Summary collapse
- #[](key) ⇒ Object
- #id ⇒ Object
-
#initialize(raw) ⇒ ResponseBase
constructor
A new instance of ResponseBase.
- #msg ⇒ Object
Constructor Details
#initialize(raw) ⇒ ResponseBase
Returns a new instance of ResponseBase.
8 9 10 |
# File 'lib/iron_mq/response.rb', line 8 def initialize(raw) @raw = raw end |
Instance Attribute Details
#raw ⇒ Object (readonly)
Returns the value of attribute raw.
6 7 8 |
# File 'lib/iron_mq/response.rb', line 6 def raw @raw end |
Instance Method Details
#[](key) ⇒ Object
12 13 14 |
# File 'lib/iron_mq/response.rb', line 12 def [](key) raw[key] end |
#id ⇒ Object
16 17 18 |
# File 'lib/iron_mq/response.rb', line 16 def id raw["id"] end |
#msg ⇒ Object
20 21 22 |
# File 'lib/iron_mq/response.rb', line 20 def msg raw["msg"] end |