public class SchemaUtils
extends java.lang.Object
Constructor and Description |
---|
SchemaUtils() |
Modifier and Type | Method and Description |
---|---|
static Schema |
parseSchema(java.lang.String schemaURI)
Get a parsed schema given a schema URI.
|
public static Schema parseSchema(java.lang.String schemaURI) throws org.jdom2.JDOMException, java.io.IOException
schemaURI
- SchemaURI as a string.java.io.IOException
- if schema URI cannot be read.org.jdom2.JDOMException
- if anything else goes wrong.
Schema URIs ending in ".rng" (any case) are assumed to point to a Relax NG schema.
Schema URIs ending in ".xsd" (any case) are assumed to point to a W3C schema.
Schema URIs ending in anything else are unrecognized.