Exception: StandardExceptions::Exception
- Inherits:
-
StandardError
- Object
- StandardError
- StandardExceptions::Exception
- Includes:
- ExceptionInterface
- Defined in:
- lib/standard_exceptions.rb
Overview
messages are based on httpstatuses.com
Direct Known Subclasses
Http::BadRequest, Http::Forbidden, Http::InternalServerError, Http::NotFound, Http::Unauthorized, Http::UnprocessableEntity
Constant Summary collapse
- MESSAGE =
'An error occurred that could not be identified'- STATUS =
500
Instance Attribute Summary
Attributes included from ExceptionInterface
Instance Method Summary collapse
-
#initialize(message = nil, status = nil, inner = nil) ⇒ Exception
constructor
A new instance of Exception.
Methods included from ExceptionInterface
Constructor Details
#initialize(message = nil, status = nil, inner = nil) ⇒ Exception
Returns a new instance of Exception.
33 34 35 36 37 |
# File 'lib/standard_exceptions.rb', line 33 def initialize(=nil,status=nil,inner=nil) super( || self.class::MESSAGE) @status = (status || self.class::STATUS) @inner = inner end |