You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@tuscany.apache.org by Christian Landbo Frederiksen <Ch...@ementor.dk> on 2007/01/29 21:24:42 UTC

java.lang.ClassCastException org.eclipse.emf.ecore.util.EcoreEList$Dynamic incompatible with commonj.sdo.DataObject

Hi 
 
I just ran into a classcast exception when I tried to call getList on a
dataobject.
 
I searched a bit for it and found this in the samples:
 
PurchaseOrderControl.removeItem(int index) {
        // TODO: this is not working due to
java.lang.ClassCastException:
        // org.eclipse.emf.ecore.util.EcoreEList$Dynamic incompatible
with commonj.sdo.DataObject
        // access a DataObject by the index and then remove it
 
 
Can anybody tell more about this?
 
/Chr

Re: java.lang.ClassCastException org.eclipse.emf.ecore.util.EcoreEList$Dynamic incompatible with commonj.sdo.DataObject

Posted by Frank Budinsky <fr...@ca.ibm.com>.
I'm guessing that the property that your calling getList() for is single 
valued. You can only call getList() on a property if the property has 
Property.isMany == true. In other words, there's no automatic conversion 
from a single valued property value to List.

Frank.

"Christian Landbo Frederiksen" <Ch...@ementor.dk> 
wrote on 01/29/2007 03:24:42 PM:

> Hi 
> 
> I just ran into a classcast exception when I tried to call getList on a
> dataobject.
> 
> I searched a bit for it and found this in the samples:
> 
> PurchaseOrderControl.removeItem(int index) {
>         // TODO: this is not working due to
> java.lang.ClassCastException:
>         // org.eclipse.emf.ecore.util.EcoreEList$Dynamic incompatible
> with commonj.sdo.DataObject
>         // access a DataObject by the index and then remove it
> 
> 
> Can anybody tell more about this?
> 
> /Chr


---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-user-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-user-help@ws.apache.org