You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@xalan.apache.org by "Edward L. Knoll" <ed...@cosd.fedex.com> on 2004/11/04 18:37:50 UTC
XSL template priority problem in SAX processing stream.
We have a XSL stylesheet which has prioritized templates. It was
working as expected when we were using org.apache.xalan.xslt.Process to
process it. We've since changed our processing to be handled by a
chain of SAX content handlers with the core XSL processing being handled
by a TransformerHandler created from a Templates handler created from a
SAXTransformerFactory.
Now it appears that template priority is not being recognized at all.
We're using Xalan-Java 2.6 on Solaris platform. We are overriding the
default version of Xalan used by the Solaris java command by overriding
the bootclasspath.
Is this a (known) Xalan-Java bug, is there something we have to
change/do to enable template prioritization, do we have to change how
prioritization values are expressed with the SAX components?
Thanks,
Ed Knoll
--
Edward L. Knoll Phone (FedEx) : (719)484-2717
e-mail (FedEx) : edward.knoll@fedex.com
e-mail (personal) : edward@elknoll.com
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-dev-help@xml.apache.org
Re: XSL template priority problem in SAX processing stream.
Posted by "Edward L. Knoll" <ed...@cosd.fedex.com>.
Please disregard this. A misedited file appeared to resolve the
problem; taking the mode attribute off did not fix the problem.
Edward L. Knoll wrote:
> I have isolated the problem further: the templates where priorities
> are not working also have mode attributes. If I take the mode
> attributes off, the templates work correctly.
>
> Unfortunately, company policy regarding software/confidential material
> will not allow me to post the input/source I'm using. However, if I
> can reproduce the problem in a smaller context, I will open the JIRA bug.
>
> Morris Kwan wrote:
>
>> I believe template priority should work in all modes of transformation,
>> without any code change from the user side. Please open a bug in the
>> JIRA
>> database (http://nagoya.apache.org/jira/secure/Dashboard.jspa) and
>> attach
>> the input xml, stylesheet and the Java code to reproduce the problem.
>>
>> Morris Kwan
>> XSLT Development
>> IBM Toronto Lab
>> Tel: (905)413-3729
>> Email: mkwan@ca.ibm.com
>>
>>
>>
>>
>>
>>
>> We have a XSL stylesheet which has prioritized templates. It was
>> working as expected when we were using org.apache.xalan.xslt.Process to
>> process it. We've since changed our processing to be handled by a
>> chain of SAX content handlers with the core XSL processing being handled
>> by a TransformerHandler created from a Templates handler created from a
>> SAXTransformerFactory.
>>
>> Now it appears that template priority is not being recognized at all.
>>
>> We're using Xalan-Java 2.6 on Solaris platform. We are overriding the
>> default version of Xalan used by the Solaris java command by overriding
>> the bootclasspath.
>>
>> Is this a (known) Xalan-Java bug, is there something we have to
>> change/do to enable template prioritization, do we have to change how
>> prioritization values are expressed with the SAX components?
>>
>>
>>
--
Edward L. Knoll Phone (FedEx) : (719)484-2717
e-mail (FedEx) : edward.knoll@fedex.com
e-mail (personal) : edward@elknoll.com
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-dev-help@xml.apache.org
Re: XSL template priority problem in SAX processing stream.
Posted by "Edward L. Knoll" <ed...@cosd.fedex.com>.
I have isolated the problem further: the templates where priorities are
not working also have mode attributes. If I take the mode attributes
off, the templates work correctly.
Unfortunately, company policy regarding software/confidential material
will not allow me to post the input/source I'm using. However, if I can
reproduce the problem in a smaller context, I will open the JIRA bug.
Morris Kwan wrote:
>I believe template priority should work in all modes of transformation,
>without any code change from the user side. Please open a bug in the JIRA
>database (http://nagoya.apache.org/jira/secure/Dashboard.jspa) and attach
>the input xml, stylesheet and the Java code to reproduce the problem.
>
>Morris Kwan
>XSLT Development
>IBM Toronto Lab
>Tel: (905)413-3729
>Email: mkwan@ca.ibm.com
>
>
>
>
>
>
>We have a XSL stylesheet which has prioritized templates. It was
>working as expected when we were using org.apache.xalan.xslt.Process to
>process it. We've since changed our processing to be handled by a
>chain of SAX content handlers with the core XSL processing being handled
>by a TransformerHandler created from a Templates handler created from a
>SAXTransformerFactory.
>
>Now it appears that template priority is not being recognized at all.
>
>We're using Xalan-Java 2.6 on Solaris platform. We are overriding the
>default version of Xalan used by the Solaris java command by overriding
>the bootclasspath.
>
>Is this a (known) Xalan-Java bug, is there something we have to
>change/do to enable template prioritization, do we have to change how
>prioritization values are expressed with the SAX components?
>
>
>
--
Edward L. Knoll Phone (FedEx) : (719)484-2717
e-mail (FedEx) : edward.knoll@fedex.com
e-mail (personal) : edward@elknoll.com
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-dev-help@xml.apache.org
Re: XSL template priority problem in SAX processing stream.
Posted by da...@us.ibm.com.
Edward Knoll writes:
>The templates at issues are actually distributed across multiple files.
>A master XSL file references these templates using <xsl:import>. If I
>change the <xsl:import> to an <xsl:include>, the prioritization works.
>...should I expect this behavior?
Yes, import precedence outweighs template priority. We have a conformance
test for this (conflictres09), so we would enforce the required behavior.
.................David Marston
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-dev-help@xml.apache.org
Re: XSL template priority problem in SAX processing stream.
Posted by Joseph Kesselman <ke...@us.ibm.com>.
Yes, you should expect that behavior.
Include treats the other file as part of the same stylesheet source
document. Import brings it in at reduced priority -- "lower Importance", if
you need a mnemonic. See the XSLT spec for details.
______________________________________
Joe Kesselman, IBM Next-Generation Web Technologies: XML, XSL and more.
"The world changed profoundly and unpredictably the day Tim Berners Lee
got bitten by a radioactive spider." -- Rafe Culpin, in r.m.filk
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-dev-help@xml.apache.org
Re: XSL template priority problem in SAX processing stream.
Posted by "Edward L. Knoll" <ed...@cosd.fedex.com>.
The templates at issues are actually distributed across multiple files.
A master XSL file references these templates using <xsl:import>. If
I change the <xsl:import> to an <xsl:include>, the prioritization works.
I've never been entirely sure of the difference between xsl:import and
xsl:include, should I expect this behavior?
Morris Kwan wrote:
>I believe template priority should work in all modes of transformation,
>without any code change from the user side. Please open a bug in the JIRA
>database (http://nagoya.apache.org/jira/secure/Dashboard.jspa) and attach
>the input xml, stylesheet and the Java code to reproduce the problem.
>
>Morris Kwan
>XSLT Development
>IBM Toronto Lab
>Tel: (905)413-3729
>Email: mkwan@ca.ibm.com
>
>
>
>
>
>
>We have a XSL stylesheet which has prioritized templates. It was
>working as expected when we were using org.apache.xalan.xslt.Process to
>process it. We've since changed our processing to be handled by a
>chain of SAX content handlers with the core XSL processing being handled
>by a TransformerHandler created from a Templates handler created from a
>SAXTransformerFactory.
>
>Now it appears that template priority is not being recognized at all.
>
>We're using Xalan-Java 2.6 on Solaris platform. We are overriding the
>default version of Xalan used by the Solaris java command by overriding
>the bootclasspath.
>
>Is this a (known) Xalan-Java bug, is there something we have to
>change/do to enable template prioritization, do we have to change how
>prioritization values are expressed with the SAX components?
>
>
>
--
Edward L. Knoll Phone (FedEx) : (719)484-2717
e-mail (FedEx) : edward.knoll@fedex.com
e-mail (personal) : edward@elknoll.com
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-dev-help@xml.apache.org
Re: XSL template priority problem in SAX processing stream.
Posted by Morris Kwan <mk...@ca.ibm.com>.
I believe template priority should work in all modes of transformation,
without any code change from the user side. Please open a bug in the JIRA
database (http://nagoya.apache.org/jira/secure/Dashboard.jspa) and attach
the input xml, stylesheet and the Java code to reproduce the problem.
Morris Kwan
XSLT Development
IBM Toronto Lab
Tel: (905)413-3729
Email: mkwan@ca.ibm.com
"Edward L. Knoll"
<ed.knoll@cosd.fe
dex.com> To
xalan-dev@xml.apache.org
11/04/2004 12:37 cc
PM
Subject
XSL template priority problem in
Please respond to SAX processing stream.
xalan-dev
We have a XSL stylesheet which has prioritized templates. It was
working as expected when we were using org.apache.xalan.xslt.Process to
process it. We've since changed our processing to be handled by a
chain of SAX content handlers with the core XSL processing being handled
by a TransformerHandler created from a Templates handler created from a
SAXTransformerFactory.
Now it appears that template priority is not being recognized at all.
We're using Xalan-Java 2.6 on Solaris platform. We are overriding the
default version of Xalan used by the Solaris java command by overriding
the bootclasspath.
Is this a (known) Xalan-Java bug, is there something we have to
change/do to enable template prioritization, do we have to change how
prioritization values are expressed with the SAX components?
Thanks,
Ed Knoll
--
Edward L. Knoll Phone (FedEx) : (719)484-2717
e-mail (FedEx) : edward.knoll@fedex.com
e-mail (personal) : edward@elknoll.com
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-dev-help@xml.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: xalan-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xalan-dev-help@xml.apache.org