Exception: HalApi::Errors::ApiError
- Inherits:
-
StandardError
- Object
- StandardError
- HalApi::Errors::ApiError
- Defined in:
- lib/hal_api/errors.rb
Direct Known Subclasses
BadFilterValueError, BadSortError, Forbidden, NotFound, UnknownFilterError, UnsupportedMediaType
Instance Attribute Summary collapse
-
#hint ⇒ Object
Returns the value of attribute hint.
-
#status ⇒ Object
Returns the value of attribute status.
Instance Method Summary collapse
-
#initialize(message = nil, status = nil, hint = nil) ⇒ ApiError
constructor
A new instance of ApiError.
Constructor Details
#initialize(message = nil, status = nil, hint = nil) ⇒ ApiError
Returns a new instance of ApiError.
9 10 11 12 13 |
# File 'lib/hal_api/errors.rb', line 9 def initialize( = nil, status = nil, hint = nil) super( || "API Error") self.status = status || 500 self.hint = hint end |
Instance Attribute Details
#hint ⇒ Object
Returns the value of attribute hint.
7 8 9 |
# File 'lib/hal_api/errors.rb', line 7 def hint @hint end |
#status ⇒ Object
Returns the value of attribute status.
6 7 8 |
# File 'lib/hal_api/errors.rb', line 6 def status @status end |