Class: Qa::Authorities::WebServiceBase
- Inherits:
-
Object
- Object
- Qa::Authorities::WebServiceBase
- Defined in:
- lib/qa/authorities/web_service_base.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#raw_response ⇒ Object
Returns the value of attribute raw_response.
-
#response ⇒ Object
Returns the value of attribute response.
Instance Method Summary collapse
-
#get_json(url) ⇒ Object
mix-in to retreive and parse JSON content from the web.
-
#results ⇒ Object
This method should be removed use #response instead.
Instance Attribute Details
#raw_response ⇒ Object
Returns the value of attribute raw_response.
6 7 8 |
# File 'lib/qa/authorities/web_service_base.rb', line 6 def raw_response @raw_response end |
#response ⇒ Object
Returns the value of attribute response.
6 7 8 |
# File 'lib/qa/authorities/web_service_base.rb', line 6 def response @response end |
Instance Method Details
#get_json(url) ⇒ Object
mix-in to retreive and parse JSON content from the web
9 10 11 12 |
# File 'lib/qa/authorities/web_service_base.rb', line 9 def get_json(url) r = RestClient.get url, {accept: :json} self.response = JSON.parse(r) end |
#results ⇒ Object
This method should be removed use #response instead
16 17 18 |
# File 'lib/qa/authorities/web_service_base.rb', line 16 def results self.response end |