Class: Hash
- Inherits:
-
Object
- Object
- Hash
- Defined in:
- lib/core_ext/hash_patch.rb
Overview
Hash extension for handling API response.
Instance Method Summary collapse
-
#error ⇒ Object
Get error element.
-
#id ⇒ Object
Get id element.
-
#result ⇒ Object
Get result element.
-
#results ⇒ Object
Get results element.
Instance Method Details
#error ⇒ Object
Get error element.
16 17 18 |
# File 'lib/core_ext/hash_patch.rb', line 16 def error self['error'] end |
#id ⇒ Object
Get id element.
12 13 14 |
# File 'lib/core_ext/hash_patch.rb', line 12 def id self['id'] end |
#result ⇒ Object
Get result element.
4 5 6 |
# File 'lib/core_ext/hash_patch.rb', line 4 def result self['result'] end |
#results ⇒ Object
Get results element.
8 9 10 |
# File 'lib/core_ext/hash_patch.rb', line 8 def results self['results'] end |