Code example for TransformerException

0
        rth.processingInstruction(javax.xml.transform.Result.PI_ENABLE_OUTPUT_ESCAPING, ""); 
      } 
    } 
    catch(SAXException se) 
    { 
      throw new TransformerException(se); 
    } 
    finally 
    { 
      if (transformer.getDebug()) { 
        try 
        { 
            // flush any pending cached processing before sending the trace event 
            transformer.getResultTreeHandler().flushPending(); 
            transformer.getTraceManager().fireTraceEndEvent(this); 
        } 
        catch (SAXException se) 
        { 
            throw new TransformerException(se); 
        }  
      }