commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Vladimirov (JIRA)" <j...@apache.org>
Subject [jira] Commented: (JXPATH-89) Cannot compare pointers that do not belong to the same tree
Date Tue, 03 Jul 2007 17:47:05 GMT

    [ https://issues.apache.org/jira/browse/JXPATH-89?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12509956
] 

Sergey Vladimirov commented on JXPATH-89:
-----------------------------------------

Matt,

The example is in original test case. I extract several variables from original tree and want
to select them (and sort) in one XPath expression.

I can't do this right now, because variables are from different trees... but is it possible
to "remember" that variables are from original tree?

> Cannot compare pointers that do not belong to the same tree
> -----------------------------------------------------------
>
>                 Key: JXPATH-89
>                 URL: https://issues.apache.org/jira/browse/JXPATH-89
>             Project: Commons JXPath
>          Issue Type: Bug
>    Affects Versions: Nightly Builds, 1.2 Final
>         Environment: codebase: 1.2 or latest version from SVN, JDK 1.4
>            Reporter: Sergey Vladimirov
>             Fix For: 1.3
>
>         Attachments: VariablePointerTestCase.java
>
>
> For XPath "$var | /MAIN/A" exception is thrown:
> org.apache.commons.jxpath.JXPathException: Cannot compare pointers that do not belong
to the same tree: '$var' and ''
> 	at org.apache.commons.jxpath.ri.model.NodePointer.compareNodePointers(NodePointer.java:665)
> 	at org.apache.commons.jxpath.ri.model.NodePointer.compareNodePointers(NodePointer.java:649)
> 	at org.apache.commons.jxpath.ri.model.NodePointer.compareNodePointers(NodePointer.java:649)
> 	at org.apache.commons.jxpath.ri.model.NodePointer.compareTo(NodePointer.java:639)
> 	at java.util.Arrays.mergeSort(Arrays.java:1152)
> 	at java.util.Arrays.sort(Arrays.java:1079)
> 	at java.util.Collections.sort(Collections.java:113)
> 	at org.apache.commons.jxpath.ri.EvalContext.constructIterator(EvalContext.java:176)
> 	at org.apache.commons.jxpath.ri.EvalContext.hasNext(EvalContext.java:100)
> 	at org.apache.commons.jxpath.JXPathContext.selectNodes(JXPathContext.java:648)
> 	at org.apache.commons.jxpath.ri.model.VariablePointerTestCase.testUnionOfVariableAndNode(VariablePointerTestCase.java:76)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message