|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.openspml.v2.util.xml.XmlParser
A wrapper around the Xerces parser that provides a simpler interface, and maintains a pool of parser objects for better performance.
This implements the Xerces ErrorHandler interface so we can intercept parser errors and mutate them. This is a slimmed down version of the XmlParser from the 1.0 toolkit. We do NOT do any validating.
| Field Summary | |
static java.lang.String |
code_id
|
| Method Summary | |
void |
error(org.xml.sax.SAXParseException ex)
Parser error callback handler We get here for things like DTD syntax errors, and DTD validation errors. |
void |
fatalError(org.xml.sax.SAXParseException ex)
Parser fatal error callback handler. |
static org.w3c.dom.Document |
parse(java.lang.String xml)
Parses a string with or without validation and returns the Document. |
org.xml.sax.InputSource |
resolveEntity(java.lang.String pubid,
java.lang.String sysid)
Attempt to resolve an entity reference to an absolute file path in the user.dir. |
static void |
setLogFailuresFile(java.io.File file)
Use this to turn on the logging of failures to the named file. |
void |
warning(org.xml.sax.SAXParseException ex)
Parser warning callback handler. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String code_id
| Method Detail |
public org.xml.sax.InputSource resolveEntity(java.lang.String pubid,
java.lang.String sysid)
throws org.xml.sax.SAXException,
java.io.IOException
resolveEntity in interface org.xml.sax.EntityResolverorg.xml.sax.SAXException
java.io.IOExceptionpublic void warning(org.xml.sax.SAXParseException ex)
warning in interface org.xml.sax.ErrorHandler
public void error(org.xml.sax.SAXParseException ex)
throws org.xml.sax.SAXParseException
error in interface org.xml.sax.ErrorHandlerorg.xml.sax.SAXParseException
public void fatalError(org.xml.sax.SAXParseException ex)
throws org.xml.sax.SAXException
fatalError in interface org.xml.sax.ErrorHandlerorg.xml.sax.SAXException
public static org.w3c.dom.Document parse(java.lang.String xml)
throws Spml2Exception
Spml2Exceptionpublic static void setLogFailuresFile(java.io.File file)
file -
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||