Exception: Routemaster::Errors::BaseError
- Inherits:
-
RuntimeError
- Object
- RuntimeError
- Routemaster::Errors::BaseError
- Defined in:
- lib/routemaster/errors.rb
Direct Known Subclasses
BadGateway, ConflictResource, FatalResource, IncompatibleVersion, InvalidResource, MethodNotAllowed, ResourceGone, ResourceNotFound, ResourceThrottling, ServiceNotAvailable, UnauthorizedResourceAccess
Instance Attribute Summary collapse
-
#env ⇒ Object
readonly
Returns the value of attribute env.
Instance Method Summary collapse
- #body ⇒ Object
- #errors ⇒ Object
-
#initialize(env) ⇒ BaseError
constructor
A new instance of BaseError.
- #message ⇒ Object
Constructor Details
#initialize(env) ⇒ BaseError
Returns a new instance of BaseError.
6 7 8 9 |
# File 'lib/routemaster/errors.rb', line 6 def initialize(env) @env = env super() end |
Instance Attribute Details
#env ⇒ Object (readonly)
Returns the value of attribute env.
4 5 6 |
# File 'lib/routemaster/errors.rb', line 4 def env @env end |
Instance Method Details
#body ⇒ Object
19 20 21 |
# File 'lib/routemaster/errors.rb', line 19 def body @body ||= deserialized_body end |
#errors ⇒ Object
11 12 13 |
# File 'lib/routemaster/errors.rb', line 11 def errors body.fetch('errors', {}) end |
#message ⇒ Object
15 16 17 |
# File 'lib/routemaster/errors.rb', line 15 def raise NotImplementedError end |