Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: [xsl] Finding deepest node

From: marcus <m-lists@---------->
To:
Date: 12/3/2005 12:09:00 AM
Michael Kay wrote:
The subject says "deepest" rather than "farthest", so I suspect the meaning
is the node with maximum depth.

Okay. I really meant "deepest". Didn't think about there being a difference.



See http://www.dpawson.co.uk/xsl/sect2/N2193.html#d3377e91

Since I don't execute this in the context of an XSLT (should have told 
you) but with a DOM (dom4j) most of the answers don't apply.



$start//node[@a = 'avalue']/@id
  [not(count(ancestor::*) lt $start//node[@a =
'avalue']/@id/count(ancestor::*))]


I'll try this one. I think I can bind a node to a variable using Jaxen.



Btw, do you have any idea how dom4j/jaxen would compare to using [some 
other DOM (XOM maybe)]/Saxon XQuery performance wise? It's in a context 
where I will be doing the same query over and over against a 
non-changing (possibly big) document. Is it possible to "compile" a 
query with Saxon against a document or can you just compile the 
expression (as you can with Jaxen)?  Do I make myself even remotely 
understandable?



Thanks



/Marcus


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