[ http://issues.apache.org/jira/browse/WSCOMMONS-95?page=all ]

Eran Chinthaka resolved WSCOMMONS-95.
-------------------------------------

    Resolution: Fixed
      Assignee: Eran Chinthaka

Thanks Toshiro. 

It would be better if you can provide a test case next time as it will improve 
the test harness of Axiom.

> OMElement.cloneOMElement() for a root element, sometimes causes 
> ClassCastException
> ----------------------------------------------------------------------------------
>
>                 Key: WSCOMMONS-95
>                 URL: http://issues.apache.org/jira/browse/WSCOMMONS-95
>             Project: WS-Commons
>          Issue Type: Bug
>          Components: AXIOM
>         Environment: Windows
>            Reporter: Toshiro Takase
>         Assigned To: Eran Chinthaka
>            Priority: Critical
>
> I got the following exception.
> ----------
> Caused by: java.lang.ClassCastException: 
> org/apache/axiom/soap/impl/llom/SOAPMessageImpl incompatible with 
> org/apache/axiom/om/impl/llom/OMNodeImpl
>       at 
> org.apache.axiom.om.impl.llom.OMNavigator.updateNextNode(OMNavigator.java:141)
>       at org.apache.axiom.om.impl.llom.OMNavigator.next(OMNavigator.java:108)
>       at 
> org.apache.axiom.om.impl.llom.OMStAXWrapper.updateNextNode(OMStAXWrapper.java:973)
>       at 
> org.apache.axiom.om.impl.llom.OMStAXWrapper.updateLastNode(OMStAXWrapper.java:962)
>       ... 16 more
> ----------
> This may be because,,,
> in org.apache.axiom.om.impl.llom.OMNavigator.updateNextNode(),
> LL.135-145
> ----------
>             OMNode nextSibling = ((OMNodeImpl) next).nextSibling;
>             //OMNode parent = next.getParent();
>             OMContainer parent = next.getParent();
>             if (nextSibling != null) {
>                 next = nextSibling;
>             } else if ((parent != null) && parent.isComplete()) {
>                 next = (OMNodeImpl) parent;
>                 backtracked = true;
>             } else {
>                 next = null;
>             }
> ----------
> L.140, parent should be not only "not null", but also "not instance of 
> OMDocument". I guess.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to