Class: Twingly::HTTP::Response
- Inherits:
-
Object
- Object
- Twingly::HTTP::Response
- Defined in:
- lib/twingly/http.rb
Instance Attribute Summary collapse
-
#body ⇒ Object
readonly
Returns the value of attribute body.
-
#final_url ⇒ Object
readonly
Returns the value of attribute final_url.
-
#headers ⇒ Object
readonly
Returns the value of attribute headers.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(headers: nil, status: nil, body: nil, final_url: nil) ⇒ Response
constructor
A new instance of Response.
Constructor Details
#initialize(headers: nil, status: nil, body: nil, final_url: nil) ⇒ Response
Returns a new instance of Response.
276 277 278 279 280 281 282 283 284 |
# File 'lib/twingly/http.rb', line 276 def initialize(headers: nil, status: nil, body: nil, final_url: nil) @headers = headers @status = status @body = body @final_url = final_url end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body.
273 274 275 |
# File 'lib/twingly/http.rb', line 273 def body @body end |
#final_url ⇒ Object (readonly)
Returns the value of attribute final_url.
274 275 276 |
# File 'lib/twingly/http.rb', line 274 def final_url @final_url end |
#headers ⇒ Object (readonly)
Returns the value of attribute headers.
271 272 273 |
# File 'lib/twingly/http.rb', line 271 def headers @headers end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
272 273 274 |
# File 'lib/twingly/http.rb', line 272 def status @status end |