final class InstanceValidator extends Object implements JsonValidator
Such a validator is only called when the schema syntax has been verified
to be correct. It is also responsible to instantiate an ArrayValidator or ObjectValidator if necessary.
| Modifier and Type | Field and Description |
|---|---|
private JsonValidatorCache |
cache |
private SchemaNode |
schemaNode |
private Set<KeywordValidator> |
validators |
| Constructor and Description |
|---|
InstanceValidator(JsonValidatorCache cache,
SchemaNode schemaNode,
Set<KeywordValidator> validators)
Constructor, package private
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
validate(ValidationContext context,
ValidationReport report,
JsonNode instance)
Validate the instance, and tell whether validation should continue
|
private final JsonValidatorCache cache
private final SchemaNode schemaNode
private final Set<KeywordValidator> validators
InstanceValidator(JsonValidatorCache cache, SchemaNode schemaNode, Set<KeywordValidator> validators)
cache - the JSON validator cacheschemaNode - the schema nodevalidators - the set of keyword validatorspublic boolean validate(ValidationContext context, ValidationReport report, JsonNode instance)
JsonValidatorNote: the return value is currently unused.
validate in interface JsonValidatorcontext - the validation contextreport - the validation reportinstance - the instance to validateCopyright © 2012. All Rights Reserved.