\r
// The following allows xml parsing without access to the dtd\r
EntityResolver resolver = new EntityResolver () {\r
+ @Override\r
public InputSource resolveEntity (String publicId, String systemId) {\r
String empty = "";\r
ByteArrayInputStream bais = new ByteArrayInputStream(empty.getBytes());\r
\r
// The following catches xml parsing exceptions\r
db.setErrorHandler(new ErrorHandler(){\r
+ @Override\r
public void error(SAXParseException saxparseexception) throws SAXException {}\r
+ @Override\r
public void warning(SAXParseException saxparseexception) throws SAXException {}\r
+ @Override\r
public void fatalError(SAXParseException saxparseexception) throws SAXException {\r
throw saxparseexception;\r
}});\r
\r
// The following allows xml parsing without access to the dtd\r
EntityResolver resolver = new EntityResolver () {\r
+ @Override\r
public InputSource resolveEntity (String publicId, String systemId) {\r
String empty = "";\r
ByteArrayInputStream bais = new ByteArrayInputStream(empty.getBytes());\r
\r
// The following catches xml parsing exceptions\r
db.setErrorHandler(new ErrorHandler(){\r
+ @Override\r
public void error(SAXParseException saxparseexception) throws SAXException {}\r
+ @Override\r
public void warning(SAXParseException saxparseexception) throws SAXException {}\r
+ @Override\r
public void fatalError(SAXParseException saxparseexception) throws SAXException {\r
throw saxparseexception;\r
}});\r
\r
// The following allows xml parsing without access to the dtd\r
EntityResolver resolver = new EntityResolver () {\r
+ @Override\r
public InputSource resolveEntity (String publicId, String systemId) {\r
String empty = "";\r
ByteArrayInputStream bais = new ByteArrayInputStream(empty.getBytes());\r
\r
// The following catches xml parsing exceptions\r
db.setErrorHandler(new ErrorHandler(){\r
+ @Override\r
public void error(SAXParseException saxparseexception) throws SAXException {}\r
+ @Override\r
public void warning(SAXParseException saxparseexception) throws SAXException {}\r
+ @Override\r
public void fatalError(SAXParseException saxparseexception) throws SAXException {\r
throw saxparseexception;\r
}});\r
\r
// The following allows xml parsing without access to the dtd\r
EntityResolver resolver = new EntityResolver () {\r
+ @Override\r
public InputSource resolveEntity (String publicId, String systemId) {\r
String empty = "";\r
ByteArrayInputStream bais = new ByteArrayInputStream(empty.getBytes());\r
\r
// The following catches xml parsing exceptions\r
db.setErrorHandler(new ErrorHandler(){\r
+ @Override\r
public void error(SAXParseException saxparseexception) throws SAXException {}\r
+ @Override\r
public void warning(SAXParseException saxparseexception) throws SAXException {}\r
+ @Override\r
public void fatalError(SAXParseException saxparseexception) throws SAXException {\r
throw saxparseexception;\r
}});\r