object Implicits extends JsonPointerInstances with JValueInstances with NonEmptyListInstances with ErrorSyntax with JValueSyntax
Groups all implicits into a single object
Method extension implicits (Syntax suffix) and implicit variables (Instances Suffix) are mixed into a single object allowing a single import statement to be used to bring them all into scope.
The required import statement is:
import com.axiell.schema.Implicits._
- Source
- Implicits.scala
- Alphabetic
- By Inheritance
- Implicits
- JValueSyntax
- ErrorSyntax
- NonEmptyListInstances
- JValueInstances
- JsonPointerInstances
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Type Members
- implicit class ErrorSyntaxOps extends AnyRef
Adds extension methods to Error via implicit class
Adds extension methods to Error via implicit class
- Definition Classes
- ErrorSyntax
- implicit class JValueSyntaxOps extends AnyRef
Adds extension methods to JValue via implicit class
Adds extension methods to JValue via implicit class
- Definition Classes
- JValueSyntax
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##(): Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- implicit val schemaJsonLocalForJValue: JsonLocal[JValue]
Implements
JsonLocal[JValue]
enabling thejsonLocal
extension method for JValue.Implements
JsonLocal[JValue]
enabling thejsonLocal
extension method for JValue. Thejson
extension method simply returns the JValue as a compact JSON string.- Definition Classes
- JValueInstances
- implicit val schemaJsonLocalForJsonPointer: JsonLocal[JsonPointer]
Implements
JsonLocal[JsonPointer]
enabling thejsonLocal
extension method for JsonPointer.Implements
JsonLocal[JsonPointer]
enabling thejsonLocal
extension method for JsonPointer.The format of the JSON string generated is the escaped version of the JSON Pointer as a string.
- Definition Classes
- JsonPointerInstances
- implicit def schemaJsonLocalForNonEmptyList[A](implicit arg0: JsonLocal[A]): JsonLocal[NonEmptyList[A]]
Implements
JsonLocal[NonEmptyList[_]]
enabling thejsonLocal
method extension for NonEmptyList.Implements
JsonLocal[NonEmptyList[_]]
enabling thejsonLocal
method extension for NonEmptyList.The format of the JSON string generated is a JSON array with each entry output as a JSON element.
- A
type of objects in list
- returns
JSON array containing each element in JSON format
- Definition Classes
- NonEmptyListInstances
- implicit val schemaShowLocalForJsonPointer: ShowLocal[JsonPointer]
Implements
ShowLocal[JsonPointer]
enabling theshowLocal
extension method for JsonPointer.Implements
ShowLocal[JsonPointer]
enabling theshowLocal
extension method for JsonPointer.The
showLocal
extension method prints out the JSON Pointer as a string.- Definition Classes
- JsonPointerInstances
- implicit def schemaShowLocalForNonEmptyList[A](implicit arg0: ShowLocal[A]): ShowLocal[NonEmptyList[A]]
Implements
ShowLocal[NonEmptyList[_]]
enabling theshowLocal
method extension for NonEmptyList.Implements
ShowLocal[NonEmptyList[_]]
enabling theshowLocal
method extension for NonEmptyList.The
showLocal
extension method prints out a comma separated list of the entires enclosed within round brackets.- A
type of objects in list
- returns
textual representation of list with comma separated elements
- Definition Classes
- NonEmptyListInstances
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
Documentation for the Axiell Schema Project
Overview
The Axiell Schema Project provides a small library for validating JSON documents against a JSON Schema. The library conforms to the JSON Schema Draft #7 specification.
The library is based on a few simple principles, namely:
Package structure
The
packages consists of a number of utilities, where each utility provides a single piece of functionality. Since the library validates JSON structures two main components are provided. The first component (com.axiell.schema
) allows JSON documents conforming to the JSON Schema specification to be read. Once read a resolution process may be required to resolve any external references defined in the document.com.axiell.schema.Schema
The second component (
) takes a resolved schema and allows JSON documents to be validated against that schema. When creating a validator it is also possible to incorporate your own "format" types for validation.com.axiell.schema.SchemaValidator
A set of auxiliary components implement parsers for many of the "format" types and can be used independently of the validator itself.
Notable utilities are:
Schema
wrapper around a JSON document containing the document itself, its$id
value and resolution mappings for all$id
and$ref
directives.SchemaValidator
takes aSchema
and an optional handler for "format" types and provides a validation method for arbitrary JSON documents.Implicits
implements implicit methods and classes used to convert one class to another or pimp methods onto existing classes (e.g.same()
method toJValue
class).EmailAddress
Hostname
Ipv4Address
Ipv6Address
JsonPointer
RelativeJsonPointer
Dependencies
The list of dependencies are:
Axiell Util Library
provides error handling classes and methods that allow multilingual error messages to be generated.JSON for Scala Library
provides mthods for dealing with JSON structures. The routines work around an AST (Abstract Syntax Tree) used to represent a JSON document.Cats Functional Programming Library
provides various traits, classes and methods that simplify functional programming in Scala. Also provides theValidated
class used to return lists of validation errors.