jackrabbit-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Podatelev" <brightnesslev...@gmail.com>
Subject Re: Select all leafs of a tree w/XPath
Date Sat, 08 Nov 2008 17:53:30 GMT
Seriously, guys, is there an easy way to select leafs or I have to implement
a particular property for this?

On Tue, Nov 4, 2008 at 3:45 AM, Sergey Podatelev <brightnesslevels@gmail.com
> wrote:

> Hello JackRabbit people,
>
> I have a problem with selection of all leaf nodes of my tree.
> The tree consists of nodes of type nt:unstructured named "testnode".
>
> I want to select all the nodes that have no children, that is, all the
> leafs.
> However, the "//testnode[not(testnode)]" query gives zero results.
>
> What is a bit more confusing, is that the "//testnode[testnode]" query
> returns all the elements of the tree, not just the ones that have at least
> one child of name "testnode".
>
> How should I select leafs?
>
> I'm sorry if the question is too dumb, but I'm not closely familiar nor to
> XPath neither to JackRabbit.
>
> --
> sp
>



-- 
sp

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message