public final class SchemaBundle extends Object
You can use this class to register a set of schemas and pass it to your schema factory via a builder.
Note that URIs must be valid, absolute JSON references, which means that not only the URI itself must be absolute, but also have no fragment or an empty fragment.
Note also that the validity of the schemas is not checked at this stage.
Constructor and Description |
---|
SchemaBundle() |
public void addSchema(URI uri, JsonNode schema)
uri
- the URI of this schemaschema
- the schema as a JSON documentIllegalArgumentException
- the URI is not an absolute JSON
Referencepublic void addSchema(String uri, JsonNode schema)
uri
- the URI of this schema as a stringschema
- the schema as a JSON documentIllegalArgumentException
- uri
is not a URI, or the
generated URI is not an absolute JSON ReferenceCopyright © 2013. All Rights Reserved.