class JSONSchema::InvalidSchemaError

Overview

Exception thrown at compile-time for any invalid schema. A schema may be invalid if the file cannot be read, the JSON string in the file is not valid JSON (cannot be parsed), or if the resulting JSON has invalid definitions for JSON Schema. Compile-time checks will throw this error if your schema cannot be turned into valid Crystal code, or to protect your application from runtime errors related to a schema that would not make logical sense.

Defined in:

error.cr

Constructors

Constructor Detail

def self.new(message : String | Nil, cause : Exception | Nil, filename : String | Nil) #

[View source]