Class AppSchemaXSDRegistry
Object
AppSchemaXSDRegistry
- All Implemented Interfaces:
XSDSchemaLocator
A singleton registry to store all XSD schema's that are created by app-schema. This registry has two purposes: (1)
Reusing schema's that have already been built previously, so that schema content in memory isn't cluttered with
multiple versions of the same schema (with respect to .
- Author:
- Niels Charlier (Curtin University of Technology)
-
Method Summary
Modifier and TypeMethodDescriptionvoid
dispose()
Flush all schema's (remove all references to them from other schema's) and clear registerstatic AppSchemaXSDRegistry
Get lazy loaded singleton instanceXSDSchema
locateSchema
(XSDSchema xsdSchema, String namespaceURI, String rawSchemaLocationURI, String resolvedSchemaLocationURI) Implements schema locator... creates and registers new schema if necessaryXSDSchema
Look up schema in registervoid
register
(XSDSchema schema) Register schema
-
Method Details
-
getInstance
Get lazy loaded singleton instance- Returns:
- singleton instance
-
register
public void register(XSDSchema schema) Register schema- Parameters:
schema
- schema to be registered
-
lookUp
Look up schema in register- Parameters:
schemaLocation
- (resolved) schema location- Returns:
- schema
-
dispose
public void dispose()Flush all schema's (remove all references to them from other schema's) and clear register -
locateSchema
public XSDSchema locateSchema(XSDSchema xsdSchema, String namespaceURI, String rawSchemaLocationURI, String resolvedSchemaLocationURI) Implements schema locator... creates and registers new schema if necessary- Specified by:
locateSchema
in interfaceXSDSchemaLocator
-