public TransformerHandler newTransformerHandler(Templates templates) throws TransformerConfigurationException {
  try {
    TransformerImpl transformer=(TransformerImpl)templates.newTransformer();
    transformer.setURIResolver(m_uriResolver);
    TransformerHandler th=(TransformerHandler)transformer.getInputContentHandler(true);
    return th;
  }
 catch (  TransformerConfigurationException ex) {
    if (m_errorListener != null) {
      try {
        m_errorListener.fatalError(ex);
        return null;
      }
 catch (      TransformerConfigurationException ex1) {
        throw ex1;
      }
catch (      TransformerException ex1) {
        throw new TransformerConfigurationException(ex1);
      }
    }
    throw ex;
  }
}

public TransformerHandler newTransformerHandler ( Templates templates ) throws TransformerConfigurationException { try { TransformerImpl transformer = ( TransformerImpl ) templates . newTransformer ( ) ; transformer . setURIResolver ( m_uriResolver ) ; TransformerHandler th = ( TransformerHandler ) transformer . getInputContentHandler ( true ) ; return th ; } catch ( TransformerConfigurationException ex ) { if ( m_errorListener != null ) { try { m_errorListener . fatalError ( ex ) ; return null ; } catch ( TransformerConfigurationException ex1 ) { throw ex1 ; } catch ( TransformerException ex1 ) { throw new TransformerConfigurationException ( ex1 ) ; } } throw ex ; } }
get a transformerhandler object that can process sax contenthandler events into a result , based on the templates argument .
