Exception: OpenTransact::HttpException

Inherits:
Exception
  • Object
show all
Defined in:
lib/opentransact/client.rb

Direct Known Subclasses

Forbidden, InsufficientFunds, Unauthorized

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ HttpException

Returns a new instance of HttpException.



106
107
108
# File 'lib/opentransact/client.rb', line 106

def initialize(response)
  @response = response
end

Instance Attribute Details

#responseObject (readonly)

Returns the value of attribute response.



105
106
107
# File 'lib/opentransact/client.rb', line 105

def response
  @response
end

Instance Method Details

#messageObject



110
111
112
# File 'lib/opentransact/client.rb', line 110

def message
  super+(" (http response code #{@response.code})")
end