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.
212 213 214 215 216 217 218 |
# File 'lib/twingly/http.rb', line 212 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.
210 211 212 |
# File 'lib/twingly/http.rb', line 210 def body @body end |
#headers ⇒ Object (readonly)
Returns the value of attribute headers.
208 209 210 |
# File 'lib/twingly/http.rb', line 208 def headers @headers end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
209 210 211 |
# File 'lib/twingly/http.rb', line 209 def status @status end |