Package com.networknt.schema.keyword
Class RecursiveRefValidator
java.lang.Object
com.networknt.schema.keyword.AbstractKeywordValidator
com.networknt.schema.keyword.BaseKeywordValidator
com.networknt.schema.keyword.RecursiveRefValidator
- All Implemented Interfaces:
KeywordValidator,Validator,Walker
KeywordValidator that resolves $recursiveRef.-
Field Summary
Fields inherited from class com.networknt.schema.keyword.BaseKeywordValidator
errorMessage, parentSchema, schemaContextFields inherited from class com.networknt.schema.keyword.AbstractKeywordValidator
schemaLocation, schemaNode -
Constructor Summary
ConstructorsConstructorDescriptionRecursiveRefValidator(SchemaLocation schemaLocation, com.fasterxml.jackson.databind.JsonNode schemaNode, Schema parentSchema, SchemaContext schemaContext) -
Method Summary
Modifier and TypeMethodDescriptiongetSchemaRef(ExecutionContext executionContext) voidvalidate(ExecutionContext executionContext, com.fasterxml.jackson.databind.JsonNode node, com.fasterxml.jackson.databind.JsonNode rootNode, NodePath instanceLocation) Validate the instance node which belongs to the instance document at the instance location.voidwalk(ExecutionContext executionContext, com.fasterxml.jackson.databind.JsonNode node, com.fasterxml.jackson.databind.JsonNode rootNode, NodePath instanceLocation, boolean shouldValidateSchema) This is default implementation of walk method.Methods inherited from class com.networknt.schema.keyword.BaseKeywordValidator
error, getNodeFieldType, getParentSchema, preloadSchemasMethods inherited from class com.networknt.schema.keyword.AbstractKeywordValidator
collectAnnotations, collectAnnotations, getKeyword, getSchemaLocation, getSchemaNode, hasAdjacentKeywordInEvaluationPath, hasUnevaluatedItemsInEvaluationPath, hasUnevaluatedPropertiesInEvaluationPath, putAnnotation, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.networknt.schema.keyword.KeywordValidator
preloadSchema
-
Constructor Details
-
RecursiveRefValidator
public RecursiveRefValidator(SchemaLocation schemaLocation, com.fasterxml.jackson.databind.JsonNode schemaNode, Schema parentSchema, SchemaContext schemaContext)
-
-
Method Details
-
validate
public void validate(ExecutionContext executionContext, com.fasterxml.jackson.databind.JsonNode node, com.fasterxml.jackson.databind.JsonNode rootNode, NodePath instanceLocation) Description copied from interface:ValidatorValidate the instance node which belongs to the instance document at the instance location.- Parameters:
executionContext- the execution contextnode- the instance node being processedrootNode- the instance document that the instance node belongs toinstanceLocation- the location of the instance node being processed
-
walk
public void walk(ExecutionContext executionContext, com.fasterxml.jackson.databind.JsonNode node, com.fasterxml.jackson.databind.JsonNode rootNode, NodePath instanceLocation, boolean shouldValidateSchema) Description copied from interface:ValidatorThis is default implementation of walk method. Its job is to call the validate method if shouldValidateSchema is enabled.- Parameters:
executionContext- the execution contextnode- the instance node being processedrootNode- the instance document that the instance node belongs toinstanceLocation- the location of the instance node being processedshouldValidateSchema- true to validate the schema while walking
-
getSchemaRef
-