jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alexandru Popescu" <the.mindstorm.mailingl...@gmail.com>
Subject Re: Xpath "or queries"
Date Sat, 01 Apr 2006 01:07:09 GMT
According to Type constraint:

Implementations are required to support constraints of one primary
type. It is optional to support constraints based on multiple primary
node types (this would, in any case, only be applicable to
implementations that supported multiple inheritance of node
types). It is also optional to support constraints on (one or more)
mixin node types.

so I would say that only the 1st form is guaranteed to work.


.w( the_mindstorm )p.

On 4/1/06, Daglian, Michael (IT) <Michael.Daglian@morganstanley.com> wrote:
> Hi everyone,
> I was wondering what the proper syntax is for executing or statements
> within an xpath query. According to the spec something like the
> following should be possible (although totally contrived in this case):
> //element(*, nt:file) or //element(*, mix:lockable)
> However, this throws a ClassCastException in the XPathQueryBuilder on
> line 322 (it appears that in the invocation of the visit method the
> SimpleNode id indicates a type of JJTROOTDESCENDANTS at a certain point
> but the data is actually an OrQueryNode and hence the cast to a
> PathQueryNode fails). I am using the 0.9 release currently. Apologies if
> this question was previously discussed or fixed in a post 0.9 candidate.
> Thanks!
> Best Regards,
> -- Mike
> --------------------------------------------------------
> NOTICE: If received in error, please destroy and notify sender.  Sender does not waive
confidentiality or privilege, and use is prohibited.

View raw message