Exception: CommunityZero::RestError
- Defined in:
- lib/community_zero/errors/rest_error.rb
Overview
A general error for failed communicate with a REST API.
Instance Attribute Summary collapse
-
#error ⇒ Object
readonly
Returns the value of attribute error.
-
#response_code ⇒ Object
readonly
Returns the value of attribute response_code.
Instance Method Summary collapse
-
#initialize(response_code, error) ⇒ RestError
constructor
A new instance of RestError.
Constructor Details
#initialize(response_code, error) ⇒ RestError
Returns a new instance of RestError.
25 26 27 28 |
# File 'lib/community_zero/errors/rest_error.rb', line 25 def initialize(response_code, error) @response_code = response_code @error = error end |
Instance Attribute Details
#error ⇒ Object (readonly)
Returns the value of attribute error.
23 24 25 |
# File 'lib/community_zero/errors/rest_error.rb', line 23 def error @error end |
#response_code ⇒ Object (readonly)
Returns the value of attribute response_code.
23 24 25 |
# File 'lib/community_zero/errors/rest_error.rb', line 23 def response_code @response_code end |