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 Wed, 04 Jul 2007 04:43:04 GMT

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

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

For example, Variables interface should allow to return not the object itself, but node pointer,
so value will be part of original tree.

Then at "sorting stage" variable is unpacked and original node pointer (if such exists) is
used.

> 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