Methods Summary |
---|
public void | error(org.xml.sax.SAXParseException ex)Error.
printError("Error", ex);
|
public void | fatalError(org.xml.sax.SAXParseException ex)Fatal error.
printError("Fatal Error", ex);
throw ex;
|
public ParserWrapper.DocumentInfo | getDocumentInfo()Returns the document information.
return this;
|
public boolean | isIgnorableWhitespace(org.w3c.dom.Text text)Returns true if the specified text node is ignorable whitespace.
return ((TextImpl)text).isIgnorableWhitespace();
|
public org.w3c.dom.Document | parse(java.lang.String uri)Parses the specified URI and returns the document.
parser.parse(uri);
return parser.getDocument();
|
protected void | printError(java.lang.String type, org.xml.sax.SAXParseException ex)Prints the error message.
System.err.print("[");
System.err.print(type);
System.err.print("] ");
String systemId = ex.getSystemId();
if (systemId != null) {
int index = systemId.lastIndexOf('/");
if (index != -1)
systemId = systemId.substring(index + 1);
System.err.print(systemId);
}
System.err.print(':");
System.err.print(ex.getLineNumber());
System.err.print(':");
System.err.print(ex.getColumnNumber());
System.err.print(": ");
System.err.print(ex.getMessage());
System.err.println();
System.err.flush();
|
public void | setFeature(java.lang.String featureId, boolean state)Sets a feature.
parser.setFeature(featureId, state);
|
public void | warning(org.xml.sax.SAXParseException ex)Warning.
printError("Warning", ex);
|