Class: WithingsAPI::Response
- Inherits:
-
Object
- Object
- WithingsAPI::Response
- Defined in:
- lib/withings_api.rb
Overview
A HTTP Response class.
Instance Method Summary collapse
-
#body ⇒ String
Returns HTTP body.
-
#headers ⇒ Net::HTTPHeader, Hash
Returns HTTP headers.
-
#initialize(res) ⇒ WithingsAPI::Response
constructor
Initializes a Response object.
Constructor Details
#initialize(res) ⇒ WithingsAPI::Response
Initializes a Response object.
139 140 141 142 143 |
# File 'lib/withings_api.rb', line 139 def initialize(res) @res = res @headers = make_headers @body = make_body end |
Instance Method Details
#body ⇒ String
Returns HTTP body.
156 157 158 |
# File 'lib/withings_api.rb', line 156 def body @body end |
#headers ⇒ Net::HTTPHeader, Hash
Returns HTTP headers.
149 150 151 |
# File 'lib/withings_api.rb', line 149 def headers @headers end |