Exception: ChefZero::RestErrorResponse
- Inherits:
-
StandardError
- Object
- StandardError
- ChefZero::RestErrorResponse
- Defined in:
- lib/chef_zero/rest_error_response.rb
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) ⇒ RestErrorResponse
constructor
A new instance of RestErrorResponse.
Constructor Details
#initialize(response_code, error) ⇒ RestErrorResponse
Returns a new instance of RestErrorResponse.
5 6 7 8 9 |
# File 'lib/chef_zero/rest_error_response.rb', line 5 def initialize(response_code, error) @response_code = response_code @error = error super "#{response_code}: #{error}" end |
Instance Attribute Details
#error ⇒ Object (readonly)
Returns the value of attribute error.
3 4 5 |
# File 'lib/chef_zero/rest_error_response.rb', line 3 def error @error end |
#response_code ⇒ Object (readonly)
Returns the value of attribute response_code.
3 4 5 |
# File 'lib/chef_zero/rest_error_response.rb', line 3 def response_code @response_code end |