[ http://issues.apache.org/jira/browse/XALANJ-1007?page=all ]

Brian Minchau updated XALANJ-1007:
----------------------------------

    Version: Latest Development Code
                 (was: 2.3)

> ElemApplyTemplate not calling pushElemTemplateElement
> -----------------------------------------------------
>
>          Key: XALANJ-1007
>          URL: http://issues.apache.org/jira/browse/XALANJ-1007
>      Project: XalanJ2
>         Type: Bug
>   Components: Xalan-interpretive, parse-or-compile
>     Versions: Latest Development Code
>  Environment: Operating System: Linux
> Platform: PC
>     Reporter: Al Byers
>     Assignee: Xalan Developers Mailing List

>
> It appears that ElemApplyTemplate calls pushElemTemplateElement for the
> childTemplates of "template", but not the template, itself. Consequently the
> element stack for use by tools is not correct.
> I seemed to have gotten it to work by the mods shown below.
> /************ starting about line 410 in ElemApplyTemplate ******/
>       //-amb, was null. Moved from above.
>       transformer.pushElemTemplateElement(template); 
>         // Fire a trace event for the template.
>         if (TransformerImpl.S_DEBUG)
>           transformer.getTraceManager().fireTraceEvent(template);
>       //-amb, added this line (or you could think of adding the above line,
>       //       as the original line had null as the argument
>       transformer.pushElemTemplateElement(null); 
>         // And execute the child templates.
>         // Loop through the children of the template, calling execute on
>         // each of them.
>         for (ElemTemplateElement t = template.m_firstChild;
>              t != null; t = t.m_nextSibling)
>         {
>           xctxt.setSAXLocator(t);
>           transformer.setCurrentElement(t);
>           t.execute(transformer);
>         }
>         //-amb, added this line. Should it go in the finally block, too?
>         transformer.popElemTemplateElement();

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to