Exception: Taro::ValidationError

Inherits:
RuntimeError show all
Defined in:
lib/taro/errors.rb

Direct Known Subclasses

InputError, ResponseError

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Error

#message

Constructor Details

#initialize(message, object, origin) ⇒ ValidationError

Returns a new instance of ValidationError.



15
16
17
18
19
20
21
# File 'lib/taro/errors.rb', line 15

def initialize(message, object, origin)
  raise 'Abstract class' if instance_of?(Taro::ValidationError)

  super(message)
  @object = object
  @origin = origin
end

Instance Attribute Details

#objectObject (readonly)

Returns the value of attribute object.



13
14
15
# File 'lib/taro/errors.rb', line 13

def object
  @object
end

#originObject (readonly)

Returns the value of attribute origin.



13
14
15
# File 'lib/taro/errors.rb', line 13

def origin
  @origin
end