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.
-
#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) ⇒ Response
constructor
A new instance of Response.
Constructor Details
#initialize(headers: nil, status: nil, body: nil) ⇒ Response
Returns a new instance of Response.
262 263 264 265 266 267 268 |
# File 'lib/twingly/http.rb', line 262 def initialize(headers: nil, status: nil, body: nil) @headers = headers @status = status @body = body end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body.
260 261 262 |
# File 'lib/twingly/http.rb', line 260 def body @body end |
#headers ⇒ Object (readonly)
Returns the value of attribute headers.
258 259 260 |
# File 'lib/twingly/http.rb', line 258 def headers @headers end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
259 260 261 |
# File 'lib/twingly/http.rb', line 259 def status @status end |