|Re: [EMF Compare] reference lists seem to be handled differently than containment lists [message #125382 is a reply to message #125343]
||Fri, 06 June 2008 23:11
Originally posted by: merks.ca.ibm.com|
Just don't cast to EObjectImpl. Cast to EObject instead. If you even
need to; what's the type?
jason henriksen wrote:
> Ha! Sorted it out!
> With references I get the reference spelled out for me:
> <subDiffElements xsi:type="diff:RemoveReferenceValue">
> href=" http:///com/ibm/example/Building.ecore#//Room/connectsToList"
> <rightElement href="altered.xml#stairs_L2"/>
> <leftElement href="original.xml#stairs_L2"/>
> <leftRemovedTarget href="original.xml#attic"/>
> With containment, I don't need it spelled out for me because I can call:
> EObjectImpl target = (EObjectImpl)cur.getRightElement();
> EStructuralFeature esf = target.eContainingFeature();
> which I was not previously aware of. From the structural feature I
> get the same info that I needed the reference tag for above.
Powered by FUDForum
. Page generated in 0.02273 seconds