private static void parse(String xml,ContentHandler contentHandler) throws SAXException {
  try {
    XMLReader reader=new ExpatReader();
    reader.setContentHandler(contentHandler);
    reader.parse(new InputSource(new StringReader(xml)));
  }
 catch (  IOException e) {
    throw new AssertionError(e);
  }
}

private static void parse ( String xml , ContentHandler contentHandler ) throws SAXException { try { XMLReader reader = new ExpatReader ( ) ; reader . setContentHandler ( contentHandler ) ; reader . parse ( new InputSource ( new StringReader ( xml ) ) ) ; } catch ( IOException e ) { throw new AssertionError ( e ) ; } }
parses the given xml string and fires events on the given sax handler .
