com.github.fge.jsonschema.core.keyword.syntax.checkers.helpers
Class SchemaOrSchemaArraySyntaxChecker

java.lang.Object
  extended by com.github.fge.jsonschema.core.keyword.syntax.checkers.AbstractSyntaxChecker
      extended by com.github.fge.jsonschema.core.keyword.syntax.checkers.helpers.SchemaOrSchemaArraySyntaxChecker
All Implemented Interfaces:
SyntaxChecker
Direct Known Subclasses:
DraftV3ItemsSyntaxChecker, DraftV4ItemsSyntaxChecker, ExtendsSyntaxChecker

public abstract class SchemaOrSchemaArraySyntaxChecker
extends AbstractSyntaxChecker

Helper class to validate the syntax of keywords having either a schema or schema array as a value


Field Summary
 
Fields inherited from class com.github.fge.jsonschema.core.keyword.syntax.checkers.AbstractSyntaxChecker
keyword
 
Constructor Summary
protected SchemaOrSchemaArraySyntaxChecker(String keyword)
           
 
Method Summary
protected  void checkValue(Collection<JsonPointer> pointers, MessageBundle bundle, ProcessingReport report, SchemaTree tree)
          Method which all syntax checkers extending this class must implement
protected abstract  void extraChecks(ProcessingReport report, MessageBundle bundle, SchemaTree tree)
          Perform extra check on the keyword
 
Methods inherited from class com.github.fge.jsonschema.core.keyword.syntax.checkers.AbstractSyntaxChecker
checkSyntax, getNode, getValidTypes, newMsg
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SchemaOrSchemaArraySyntaxChecker

protected SchemaOrSchemaArraySyntaxChecker(String keyword)
Method Detail

checkValue

protected final void checkValue(Collection<JsonPointer> pointers,
                                MessageBundle bundle,
                                ProcessingReport report,
                                SchemaTree tree)
                         throws ProcessingException
Description copied from class: AbstractSyntaxChecker
Method which all syntax checkers extending this class must implement

At this point, it is known that the keyword's value has at least the correct type.

Specified by:
checkValue in class AbstractSyntaxChecker
Parameters:
pointers - the list of JSON Pointers to fill (see description)
bundle - the message bundle to use
report - the processing report to use
tree - the schema
Throws:
InvalidSchemaException - keyword is invalid
ProcessingException

extraChecks

protected abstract void extraChecks(ProcessingReport report,
                                    MessageBundle bundle,
                                    SchemaTree tree)
                             throws ProcessingException
Perform extra check on the keyword

Parameters:
report - the report to use
bundle - the message bundle to use
tree - the schema
Throws:
InvalidSchemaException - schema is invalid
ProcessingException