org.apache.felix.ipojo.xml.parser
Class SchemaResolver
java.lang.Object
org.apache.felix.ipojo.xml.parser.SchemaResolver
- All Implemented Interfaces:
- org.xml.sax.EntityResolver
public class SchemaResolver
- extends Object
- implements org.xml.sax.EntityResolver
Entity Resolver loading embedded XML Schemas.
This resolver avoid using a network connection to get schemas as they
are loaded from the manipulator jar file.
- Author:
- Felix Project Team
Field Summary |
static String |
XSD_PATH
Directory where embedded schemas are copied. |
Method Summary |
org.xml.sax.InputSource |
resolveEntity(String publicId,
String systemId)
Resolves systemIds to use embedded schemas. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XSD_PATH
public static final String XSD_PATH
- Directory where embedded schemas are copied.
- See Also:
- Constant Field Values
SchemaResolver
public SchemaResolver()
resolveEntity
public org.xml.sax.InputSource resolveEntity(String publicId,
String systemId)
throws org.xml.sax.SAXException,
IOException
- Resolves systemIds to use embedded schemas. The schemas are loaded from
the
XSD_PATH
directory with the current classloader.
- Specified by:
resolveEntity
in interface org.xml.sax.EntityResolver
- Parameters:
publicId
- the publicIdsystemId
- the systemId (Schema URL)
- Returns:
- the InputSource to load the schemas or
null
if the schema
cannot be loaded (not embedded)
- Throws:
org.xml.sax.SAXException
- cannot happen
IOException
- when the embedded resource cannot be read correctly- See Also:
EntityResolver.resolveEntity(java.lang.String, java.lang.String)
Copyright © 2006-2011 Apache Software Foundation. All Rights Reserved.