This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: Storing xpath expressions in a vaiable
- To: xsl-list at mulberrytech dot com
- Subject: Re: Storing xpath expressions in a vaiable
- From: Paul Tchistopolskii <paul at qub dot com>
- Date: Thu, 28 Sep 2000 19:07:35 -0700
- Organization: The Qub Group
- References: <OF01DD3DA3.2485C17D-ON88256968.00764A45@i2.com>
- Reply-To: xsl-list at mulberrytech dot com
From: <Sridhar_Ramachandran@i2.com>
>
> Hi,
> I am trying to store an xpath expression in variable and trying to
> evaluate it and storing the results in another variable. The xpath
> expression used might depend on the value of some parameter(s) passed to
> the style sheet.
Welcome to the club.
The simplest solution is to use SAXON engine
which understands saxon:evaluate extension function.
saxon:evaluate is not a part of W3C specs so it is
not portable.
I have implemented the xml 'grep' in 'plain'
XSLT ( my xml 'grep' is part of Ux v 0.3
available for browsing at http://www.pault.com/Ux/)
I came to conclusion that :
<conclusion>
For some cases saxon:evaluate is *much* better than
any conformant solution.
</conclusion>
I think the number of those cases will keep growing.
The more flexible ( and universal ) you want your stylesheet
to be - the bigger is your need in saxon:evaluate.
So maybe Sebastian was in some way correct when
he was talking about his 'naive' usage of XSLT ;-)
Rgds.Paul.
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list