@Immutable public final class JsonValidator extends Object
One such instance exists per JsonSchemaFactory
. In fact, you have
to go through a factory to obtain an instance.
This class is also responsible for building JsonSchema
instances.
JsonSchemaFactory.getValidator()
Modifier and Type | Method and Description |
---|---|
ProcessingReport |
validate(JsonNode schema,
JsonNode instance)
Validate a schema/instance pair
|
ProcessingReport |
validateUnchecked(JsonNode schema,
JsonNode instance)
Validate a schema/instance pair (unchecked mode)
|
public ProcessingReport validate(JsonNode schema, JsonNode instance) throws ProcessingException
schema
- the schemainstance
- the instanceProcessingException
- an exception occurred during validationProcessingError
- the schema or instance is nullpublic ProcessingReport validateUnchecked(JsonNode schema, JsonNode instance)
The same warnings as described in JsonSchema.validateUnchecked(JsonNode)
apply
schema
- the schemainstance
- the instanceProcessingError
- the schema or instance is nullCopyright © 2013. All Rights Reserved.