if (targetException != null)
if (targetException instanceof TransformerException) throw (TransformerException)targetException; else if (targetException != null)
  public void processElement(String localPart,                             ElemTemplateElement element,                             TransformerImpl transformer,                             Stylesheet stylesheetTree,                             Object methodKey)    throws TransformerException, IOException  {    Object result = null;    Method m = (Method) getFromCache(methodKey, null, null);    if (null == m)    {      try      {        m = MethodResolver.getElementMethod(m_classObj, localPart);        if ( (null == m_defaultInstance) && !Modifier.isStatic(m.getModifiers()) )          m_defaultInstance = m_classObj.newInstance();      }      catch (Exception e)      {        // e.printStackTrace ();        throw new TransformerException (e.getMessage (), e);      }      putToCache(methodKey, null, null, m);    }    XSLProcessorContext xpc = new XSLProcessorContext(transformer,                                                       stylesheetTree);    try    {      result = m.invoke(m_defaultInstance, new Object[] {xpc, element});    }    catch (InvocationTargetException e)    {      Throwable targetException = e.getTargetException();            if (targetException != null)        throw new TransformerException (targetException.getMessage (), targetException);      else        throw new TransformerException (e.getMessage (), e);    }    catch (Exception e)    {      // e.printStackTrace ();      throw new TransformerException (e.getMessage (), e);    }    if (result != null)    {      xpc.outputToResultTree (stylesheetTree, result);    }   }