Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: [xml-dev] XSLT: Variable href in

From: Jeni Tennison <jeni@------------.--->
To: David Carlisle <davidc@---.--.-->
Date: 8/11/2004 2:26:00 PM
David,

>   Any idea if this will change in xslt 2.0? Couldn't really find it in the
>   rec (http://www.w3.org/TR/xslt20/) but it seems like a change which is
>   plausible enough.
>
> No, chance: it would completely break the xslt processing model, you
> can't evaluate any expressions unless you know all functions.
> variables templates etc that are defined, and you can't know that
> until _after_ the stylesheet has been assembled by following the
> xsl:import.

It's not quite that clear-cut. If you restrict the static and dynamic
context information that you can use within an XPath, you can
effectively limit the XPath to using only information that is
available at compile time. You can say, for example, that there aren't
any in-scope variables that can be referred to, that the only
functions that are available are the built-in ones, and that there's
no context item. There are still a few useful things that you can do
even with such restrictions, such as evaluating:

  system-property('xsl:is-schema-aware') = "yes"

to see if the XSLT processor is schema aware, and include different
stylesheets based on whether it is or isn't.

Of course, including different stylesheets based on a parameter value
would still be a no-no, but that's because parameter values aren't
available at compile time, not because you can never evaluate any
XPath at compile time.

(Take a look at xsl:use-when when the next draft of XSLT 2.0 comes
out...)

Cheers,

Jeni

---
Jeni Tennison
http://www.jenitennison.com/


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent