Versions in this module Expand all Collapse all v2 v2.1.1 Feb 6, 2020 Changes in this version + var Decoders = map[string]func(string) ([]byte, error) + var Draft4 = &Draft + var Draft6 = &Draft + var Draft7 = &Draft + var Formats = map[string]func(interface{}) bool + var LoadURL = func(s string) (io.ReadCloser, error) + var Loaders = map[string]func(url string) (io.ReadCloser, error) + var MediaTypes = map[string]func([]byte) error + func DecodeJSON(r io.Reader) (interface{}, error) + type Compiler struct + Draft *Draft + ExtractAnnotations bool + LoadURL func(s string) (io.ReadCloser, error) + func NewCompiler() *Compiler + func (c *Compiler) AddResource(url string, r io.Reader) error + func (c *Compiler) Compile(url string) (*Schema, error) + func (c *Compiler) MustCompile(url string) *Schema + type Draft struct + type InvalidJSONTypeError string + func (e InvalidJSONTypeError) Error() string + type Schema struct + AdditionalItems interface{} + AdditionalProperties interface{} + AllOf []*Schema + Always *bool + AnyOf []*Schema + Constant []interface{} + Contains *Schema + ContentEncoding string + ContentMediaType string + Default interface{} + Dependencies map[string]interface{} + Description string + Else *Schema + Enum []interface{} + Examples []interface{} + ExclusiveMaximum *big.Float + ExclusiveMinimum *big.Float + Format string + If *Schema + Items interface{} + MaxItems int + MaxLength int + MaxProperties int + Maximum *big.Float + MinItems int + MinLength int + MinProperties int + Minimum *big.Float + MultipleOf *big.Float + Not *Schema + OneOf []*Schema + Pattern *regexp.Regexp + PatternProperties map[*regexp.Regexp]*Schema + Properties map[string]*Schema + PropertyNames *Schema + Ptr string + ReadOnly bool + Ref *Schema + RegexProperties bool + Required []string + Then *Schema + Title string + Types []string + URL string + UniqueItems bool + WriteOnly bool + func Compile(url string) (*Schema, error) + func MustCompile(url string) *Schema + func (s *Schema) Validate(r io.Reader) error + func (s *Schema) ValidateInterface(doc interface{}) (err error) + type SchemaError struct + Err error + SchemaURL string + func (se *SchemaError) Error() string + type SchemeNotRegisteredError string + func (s SchemeNotRegisteredError) Error() string + type ValidationError struct + Causes []*ValidationError + InstancePtr string + Message string + SchemaPtr string + SchemaURL string + func (ve *ValidationError) Error() string + func (ve *ValidationError) MessageFmt() string Other modules containing this package github.com/SimingLiu/jsonschema