Exception: HyperResource::Exception

Inherits:
StandardError
  • Object
show all
Defined in:
lib/hyper_resource/exceptions.rb

Direct Known Subclasses

ResponseError

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, attrs = {}) ⇒ Exception

Returns a new instance of Exception.



6
7
8
9
# File 'lib/hyper_resource/exceptions.rb', line 6

def initialize(message, attrs={}) # @private
  self.cause = attrs[:cause]
  super(message)
end

Instance Attribute Details

#causeObject

The internal exception which led to this one, if any.



4
5
6
# File 'lib/hyper_resource/exceptions.rb', line 4

def cause
  @cause
end