This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: BAST METHOD


> Never use '//'! So the most explicit path is the best:
>
> /document/head/title
>
Yes. Or even /document[1]/head[1]/title[1]; though that's second-guessing
the optimization that the processor does.

Actually with Saxon, assuming there is a single <title> element in the
document, //title will be a lot more expensive than /document/head/title the
first time it is used, but it will be slightly cheaper on the second and
subsequent occasions; but on the other hand, if you are going to use it
repeatedly, it would be better to use a global variable.

Michael Kay
Software AG
home: Michael.H.Kay@ntlworld.com
work: Michael.Kay@softwareag.com


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]