[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: alternative to repeatedly walking the ancestor axi

Subject: Re: alternative to repeatedly walking the ancestor axis in 1.0
From: "Andrew Welch" <andrew.j.welch@xxxxxxxxx>
Date: Mon, 4 Aug 2008 16:08:39 +0100
Re:  alternative to repeatedly walking the ancestor axi
> I submit that speculating on performance differences vs alternatives is
> somewhat pointless, since it will depend on the implementation. It's not
> that it couldn't be optimized (especially if it were supported in the
> parser), so much as that it might not be.

In that case Wendell, there's no need to discourage anyone from using //

;-)

(it's optimised in Saxon SA, but not others)

Just to recap:

- in 1.0 you don't have tunnelled parameters so you either pass the
information explicitly through each template which is prone to error
(and bad for your sanity), or you get it from the ancestor axis, which
could be expensive (and also isn't what you'd call elegant)

- there is xml:lang and the lang() function, which were invented for
this particular task, but many implementations (including Saxon) will
just walk the ancestor axis behind the scenes, so you don't benefit
from switching to xml:lang from a proprietary solution

This really isn't about premature optimisation...

-- 
Andrew Welch
http://andrewjwelch.com
Kernow: http://kernowforsaxon.sf.net/

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.