use of org.xml.sax.SAXNotSupportedException in project j2objc by google.
the class SAXNotSupportedExceptionTest method testSAXNotSupportedException_String.
public void testSAXNotSupportedException_String() {
SAXNotSupportedException e = new SAXNotSupportedException(ERR);
assertEquals(ERR, e.getMessage());
e = new SAXNotSupportedException(null);
assertNull(e.getMessage());
}
use of org.xml.sax.SAXNotSupportedException in project pentaho-kettle by pentaho.
the class XMLInputSaxFieldRetriever method parseDocument.
private void parseDocument() {
// get a factory
SAXParserFactory spf = null;
try {
spf = XMLParserFactoryProducer.createSecureSAXParserFactory();
} catch (SAXNotSupportedException | SAXNotRecognizedException | ParserConfigurationException ex) {
log.logError(ex.getMessage());
}
try {
// get a new instance of parser
SAXParser sp = spf.newSAXParser();
// parse the file and also register this class for call backs
sp.parse(sourceFile, this);
} catch (SAXException se) {
log.logError(Const.getStackTracker(se));
} catch (ParserConfigurationException pce) {
log.logError(Const.getStackTracker(pce));
} catch (IOException ie) {
log.logError(Const.getStackTracker(ie));
}
}
use of org.xml.sax.SAXNotSupportedException in project pentaho-kettle by pentaho.
the class XMLInputSaxDataRetriever method parseDocument.
private void parseDocument() {
// get a factory
SAXParserFactory spf = null;
try {
spf = XMLParserFactoryProducer.createSecureSAXParserFactory();
} catch (SAXNotSupportedException | SAXNotRecognizedException | ParserConfigurationException ex) {
log.logError(ex.getMessage());
}
try {
// get a new instance of parser
SAXParser sp = spf.newSAXParser();
// parse the file and also register this class for call backs
sp.parse(sourceFile, this);
} catch (SAXException se) {
log.logError(Const.getStackTracker(se));
} catch (ParserConfigurationException pce) {
log.logError(Const.getStackTracker(pce));
} catch (IOException ie) {
log.logError(Const.getStackTracker(ie));
}
}
Aggregations