Class: Idnow::JsonResponse
- Inherits:
-
RawResponse
- Object
- RawResponse
- Idnow::JsonResponse
- Defined in:
- lib/idnow/json_response.rb
Instance Attribute Summary collapse
-
#data ⇒ Object
readonly
Returns the value of attribute data.
Attributes inherited from RawResponse
Instance Method Summary collapse
-
#initialize(raw_response) ⇒ JsonResponse
constructor
A new instance of JsonResponse.
Methods inherited from RawResponse
Constructor Details
#initialize(raw_response) ⇒ JsonResponse
Returns a new instance of JsonResponse.
7 8 9 10 11 |
# File 'lib/idnow/json_response.rb', line 7 def initialize(raw_response) super raw_response = '{}' if raw_response == '' @data = JSON.parse(raw_response) end |
Instance Attribute Details
#data ⇒ Object (readonly)
Returns the value of attribute data.
5 6 7 |
# File 'lib/idnow/json_response.rb', line 5 def data @data end |