json_schema v0.3.0 JsonSchema.Parser.ErrorUtil View Source
Contains helper functions for reporting parser errors.
Link to this section Summary
Functions
Returns the name of the type of the given value.
Link to this section Functions
Returns the name of the type of the given value.
Examples
iex> get_type([1,2,3])
"list"
iex> get_type(%{"type" => "string"})
"object"
iex> get_type("name")
"string"
iex> get_type(42)
"integer"
Link to this function
invalid_type(identifier, property, expected_type, actual_value)
View Sourceinvalid_type( JsonSchema.Types.typeIdentifier(), String.t(), String.t(), String.t() ) :: JsonSchema.Parser.ParserError.t()
Link to this function
invalid_uri(identifier, property, actual)
View Sourceinvalid_uri(JsonSchema.Types.typeIdentifier(), String.t(), String.t()) :: JsonSchema.Parser.ParserError.t()
Link to this function
missing_property(identifier, property)
View Sourcemissing_property(JsonSchema.Types.typeIdentifier(), String.t()) :: JsonSchema.Parser.ParserError.t()
Link to this function
name_collision(identifier)
View Sourcename_collision(JsonSchema.Types.typeIdentifier()) :: JsonSchema.Parser.ParserError.t()
Link to this function
name_not_a_regex(identifier, property)
View Sourcename_not_a_regex(JsonSchema.Types.typeIdentifier(), String.t()) :: JsonSchema.Parser.ParserError.t()
Link to this function
schema_name_collision(identifier)
View Sourceschema_name_collision(JsonSchema.Types.typeIdentifier()) :: JsonSchema.Parser.ParserError.t()
Link to this function
unexpected_type(identifier, error_msg)
View Sourceunexpected_type(JsonSchema.Types.typeIdentifier(), String.t()) :: JsonSchema.Parser.ParserError.t()
Link to this function
unknown_enum_type(type_name)
View Sourceunknown_enum_type(String.t()) :: JsonSchema.Parser.ParserError.t()
Link to this function
unknown_node_type(identifier, name, schema_node)
View Sourceunknown_node_type( JsonSchema.Types.typeIdentifier(), String.t(), JsonSchema.Types.schemaNode() ) :: JsonSchema.Parser.ParserError.t()
Link to this function
unknown_primitive_type(type_name)
View Sourceunknown_primitive_type(String.t()) :: JsonSchema.Parser.ParserError.t()
Link to this function
unknown_type(type_name)
View Sourceunknown_type(String.t()) :: JsonSchema.Parser.ParserError.t()
Link to this function
unresolved_reference(identifier, parent)
View Sourceunresolved_reference(JsonSchema.Types.typeIdentifier(), URI.t()) :: JsonSchema.Parser.ParserError.t()
Link to this function
unsupported_schema_version(supplied_value, supported_versions)
View Sourceunsupported_schema_version(String.t(), [String.t()]) :: JsonSchema.Parser.ParserError.t()