Exception: JSON::ValidationError

Inherits:
Exception
  • Object
show all
Defined in:
lib/json-schema/validator.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, fragments, schema) ⇒ ValidationError

Returns a new instance of ValidationError.



12
13
14
15
16
# File 'lib/json-schema/validator.rb', line 12

def initialize(message, fragments, schema)
  @fragments = fragments
  @schema = schema
  super(message)
end

Instance Attribute Details

#fragmentsObject (readonly)

Returns the value of attribute fragments.



10
11
12
# File 'lib/json-schema/validator.rb', line 10

def fragments
  @fragments
end

#schemaObject (readonly)

Returns the value of attribute schema.



10
11
12
# File 'lib/json-schema/validator.rb', line 10

def schema
  @schema
end