private SAXParser createParser(final SAXParserFactory factory) throws ParserConfigurationException, SAXException {
  final SAXParser parser=factory.newSAXParser();
  final XMLReader reader=parser.getXMLReader();
  try {
    reader.setFeature("http://xml.org/sax/features/validation",false);
    reader.setFeature("http://apache.org/xml/features/nonvalidating/load-external-dtd",false);
  }
 catch (  SAXNotRecognizedException exception) {
  }
catch (  SAXNotSupportedException exception) {
  }
  return parser;
}

private SAXParser createParser ( final SAXParserFactory factory ) throws ParserConfigurationException , SAXException { final SAXParser parser = factory . newSAXParser ( ) ; final XMLReader reader = parser . getXMLReader ( ) ; try { reader . setFeature ( "http://xml.org/sax/features/validation" , false ) ; reader . setFeature ( "http://apache.org/xml/features/nonvalidating/load-external-dtd" , false ) ; } catch ( SAXNotRecognizedException exception ) { } catch ( SAXNotSupportedException exception ) { } return parser ; }
creates a new parser from the specified factory .
