Class: Apipony::Response
Instance Attribute Summary collapse
-
#body ⇒ Object
Returns the value of attribute body.
-
#headers ⇒ Object
Returns the value of attribute headers.
-
#status ⇒ Object
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(status, &block) ⇒ Response
constructor
A new instance of Response.
Constructor Details
#initialize(status, &block) ⇒ Response
Returns a new instance of Response.
4 5 6 7 8 |
# File 'lib/apipony/response.rb', line 4 def initialize(status, &block) @status = status instance_eval(&block) if block_given? end |
Instance Attribute Details
#body ⇒ Object
Returns the value of attribute body.
2 3 4 |
# File 'lib/apipony/response.rb', line 2 def body @body end |
#headers ⇒ Object
Returns the value of attribute headers.
2 3 4 |
# File 'lib/apipony/response.rb', line 2 def headers @headers end |
#status ⇒ Object
Returns the value of attribute status.
2 3 4 |
# File 'lib/apipony/response.rb', line 2 def status @status end |