code: public Transformer getXmlTransformer(final String ideal)
        throws TransformerException, ServletException, FileNotFoundException {
      String url = lookupPath(ideal);
      if (debug()) {
        debug("getXmlTransformer: ideal = " + ideal +
                          " actual = " + url);
      }
      Transformer trans = transformers.get(url);
  
      if (trans != null) {
        return trans;
      }
  
      try {
        trans = tf.newTransformer(new StreamSource(url));
      } catch (TransformerConfigurationException tce) {
        /** Work our way down the chain to see if we have an embedded file
         * not found. If so, throw that to let the caller try another path.
         */
        Throwable cause = tce.getCause();
        while (cause instanceof TransformerException) {
          cause = ((TransformerException)cause).getCause();
        }
  
        if (!(cause instanceof FileNotFoundException)) {
          throw tce;
        }
  
        throw (FileNotFoundException)cause;
      } catch (final Exception e) {
        error("Could not initialize transform for " + url);
        error(e);
        throw new ServletException("Could not initialize transform for " + url, e);
      } finally {
    /*    if (is != null) {
          try {
            is.close();
          } catch (Exception fe) {}
        } */
      }
  
      synchronized (transformers) {
        Transformer trans2 = transformers.get(url);
  
        if (trans2 != null) {
          // somebody beat us to it.
          return trans2;
        }
  
        transformers.put(url, trans);
      }
  
      return trans;
    }
docs: This method will only do something if there is no current XML transformer.
  A previous call to setXslt will discard any previous transformer.
  <p>Subclasses could call setXslt then call this method to check that the
  stylesheet is valid. A TransformerException provides inforamtion about
  where any error occuured.
  
  @param ideal          'ideal' path of the stylesheet
  @return  Transformer  Existing or new XML transformer
  @throws TransformerException
  @throws ServletException
  @throws FileNotFoundException