Module: Rest::InternalClient::Response
- Includes:
- AbstractResponse
- Defined in:
- lib/rest/wrappers/internal_client/internal/response.rb
Overview
A Response from InternalClient, you can access the response body, the code or the headers.
Instance Attribute Summary collapse
-
#args ⇒ Object
Returns the value of attribute args.
- #body ⇒ Object
-
#net_http_res ⇒ Object
Returns the value of attribute net_http_res.
Class Method Summary collapse
Methods included from AbstractResponse
beautify_headers, #code, #cookies, #description, #follow_redirection, #headers, #raw_headers, #return!, #to_i
Instance Attribute Details
#args ⇒ Object
Returns the value of attribute args.
10 11 12 |
# File 'lib/rest/wrappers/internal_client/internal/response.rb', line 10 def args @args end |
#body ⇒ Object
14 15 16 |
# File 'lib/rest/wrappers/internal_client/internal/response.rb', line 14 def body self end |
#net_http_res ⇒ Object
Returns the value of attribute net_http_res.
10 11 12 |
# File 'lib/rest/wrappers/internal_client/internal/response.rb', line 10 def net_http_res @net_http_res end |
Class Method Details
.create(body, net_http_res, args) ⇒ Object
18 19 20 21 22 23 24 |
# File 'lib/rest/wrappers/internal_client/internal/response.rb', line 18 def Response.create body, net_http_res, args result = body || '' result.extend Response result.net_http_res = net_http_res result.args = args result end |