Exception: Gateway::Error

Inherits:
RuntimeError
  • Object
show all
Defined in:
lib/gateway/errors.rb

Direct Known Subclasses

BadGateway, GatewayTimeout

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#inner_errorObject

Returns the value of attribute inner_error.



3
4
5
# File 'lib/gateway/errors.rb', line 3

def inner_error
  @inner_error
end

#statusObject

Returns the value of attribute status.



3
4
5
# File 'lib/gateway/errors.rb', line 3

def status
  @status
end

Class Method Details

.wrap(error) ⇒ Object



4
5
6
7
8
# File 'lib/gateway/errors.rb', line 4

def self.wrap(error)
  e = self.new("#{self.name} - #{error.class.name}: #{error.message}")
  e.inner_error = error
  e
end