com.github.fge.jsonschema.keyword.digest
Interface Digester

All Known Implementing Classes:
AbstractDigester, AdditionalItemsDigester, AdditionalPropertiesDigester, ArraySchemaDigester, DivisibleByDigester, DraftV3DependenciesDigester, DraftV3PropertiesDigester, DraftV3TypeKeywordDigester, DraftV4DependenciesDigester, DraftV4TypeDigester, IdentityDigester, MaximumDigester, MinimumDigester, MultipleOfDigester, NullDigester, NumericDigester, ObjectSchemaDigester, RequiredDigester, SimpleDigester

public interface Digester

Interface for a digester

A digester, as its name implies, digests a schema (which comes here as a JsonNode) and returns a simplified form of it, according to its context.

It is mainly used for keywords, for building a simplified form of a schema in order to ease the job of keyword construction; but most importantly, it also reports the instance types supported by this keyword.

It is also used to build a digested form of schemas for array/object schema selections.

See Also:
SchemaDigester, KeywordValidator, ArraySchemaDigester, ObjectSchemaDigester

Method Summary
 JsonNode digest(JsonNode schema)
          Digest a schema into a simplified form
 EnumSet<NodeType> supportedTypes()
          Return the instance types handled by this digested form
 

Method Detail

supportedTypes

EnumSet<NodeType> supportedTypes()
Return the instance types handled by this digested form

Returns:
a set of NodeTypes

digest

JsonNode digest(JsonNode schema)
Digest a schema into a simplified form

Parameters:
schema - the schema to digest
Returns:
the digested form


Copyright © 2014. All Rights Reserved.