|
Re: EAnnotation and DynamicEObjectImpl [message #502022 is a reply to message #502016] |
Fri, 04 December 2009 19:35 |
Ed Merks Messages: 33140 Registered: July 2009 |
Senior Member |
|
|
Chessman,
Comments below.
Chessman wrote:
> I am developing a tool to control ecore metamodel and model versions.
> I'm using eAnnotation to put version information in the models.
> However, when a model os loaded, it ts generated DynamicEObjectImpl
> instances instead of a EModelElement descendant. Therefore, I am not
> been able to access aAnnotations reference. The metamodel's elements
> are all descendents of EModelElement. Does anybody know how to access
> eAnnotations from a DynamicEObjectImpl instance?
Not all models extend Ecore. In fact I typically advise against
extending Ecore. It sounds like there's some meta-level confusion
here. You should go from your instance to the Ecore model of it using
EObject.eClass() and from that EClass you'll be able to fetch the
EAnnotations associated with it.
>
> Thank you.
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Powered by
FUDForum. Page generated in 0.02892 seconds