Exception: Gateway::BadResponse
- Inherits:
-
BadGateway
- Object
- RuntimeError
- Error
- BadGateway
- Gateway::BadResponse
- Defined in:
- lib/gateway/errors.rb
Overview
When a response is returned, but is considered unsuccessful. This is application specific. For HTTP responses: 4xx, 5xx can be considered bad response
Instance Attribute Summary collapse
-
#info ⇒ Object
Returns the value of attribute info.
Attributes inherited from Error
Instance Method Summary collapse
-
#initialize(msg, info = nil) ⇒ BadResponse
constructor
A new instance of BadResponse.
Methods inherited from Error
Constructor Details
#initialize(msg, info = nil) ⇒ BadResponse
Returns a new instance of BadResponse.
33 34 35 36 37 |
# File 'lib/gateway/errors.rb', line 33 def initialize(msg, info=nil) msg = "#{msg}\nInfo:\n#{info.inspect}" if info super msg self.info = info end |
Instance Attribute Details
#info ⇒ Object
Returns the value of attribute info.
32 33 34 |
# File 'lib/gateway/errors.rb', line 32 def info @info end |