| Constructor and Description |
|---|
SchemaLoaderUtils() |
| Modifier and Type | Method and Description |
|---|---|
static String |
getSystemId(Resource resource)
Retrieves the URL from the given resource as System ID.
|
static Schema |
loadSchema(Resource[] resources,
String schemaLanguage)
Load schema from the given resource.
|
static Schema |
loadSchema(Resource resource,
String schemaLanguage)
Load schema from the given resource.
|
public static Schema loadSchema(Resource resource, String schemaLanguage) throws IOException, SAXException
resource - the resource to load fromschemaLanguage - the language of the schema. Can be XMLConstants.W3C_XML_SCHEMA_NS_URI or
XMLConstants.RELAXNG_NS_URI.IOException - if loading failedSAXException - if loading failedXMLConstants.W3C_XML_SCHEMA_NS_URI,
XMLConstants.RELAXNG_NS_URIpublic static Schema loadSchema(Resource[] resources, String schemaLanguage) throws IOException, SAXException
resources - the resources to load fromschemaLanguage - the language of the schema. Can be XMLConstants.W3C_XML_SCHEMA_NS_URI or
XMLConstants.RELAXNG_NS_URI.IOException - if loading failedSAXException - if loading failedXMLConstants.W3C_XML_SCHEMA_NS_URI,
XMLConstants.RELAXNG_NS_URI