Class: CouchRest::Response
- Inherits:
-
Hash
- Object
- Hash
- CouchRest::Response
- Defined in:
- lib/couchrest/response.rb
Direct Known Subclasses
Instance Method Summary collapse
- #[](key) ⇒ Object
- #[]=(key, value) ⇒ Object
-
#initialize(pkeys = {}) ⇒ Response
constructor
A new instance of Response.
Constructor Details
#initialize(pkeys = {}) ⇒ Response
Returns a new instance of Response.
3 4 5 6 7 8 |
# File 'lib/couchrest/response.rb', line 3 def initialize(pkeys = {}) pkeys ||= {} pkeys.each do |k,v| self[k.to_s] = v end end |
Instance Method Details
#[](key) ⇒ Object
12 13 14 |
# File 'lib/couchrest/response.rb', line 12 def [](key) super(key.to_s) end |
#[]=(key, value) ⇒ Object
9 10 11 |
# File 'lib/couchrest/response.rb', line 9 def []=(key, value) super(key.to_s, value) end |