|Re: [EMF] Reusable Annotations [message #1750487 is a reply to message #1750471]
||Wed, 21 December 2016 15:47
| Ioan Salau
Registered: July 2009
Thanks Ed&Felix for your quick feedback. I am using KDM model instances (Knowledge Discovery Model from OMG ) which has Annotation and Tag class defined, but I guess your suggestions works as KDM and Annotations/Tags works similar with Ecore and EAnnotations. My target is to build a Software Production Line as a chain of transformations, the starting point being a set of EMF models obtained by MoDisco discoverers. In each phase, I want to inject extra information to address variability points ( mainly directives for transformations ) which will help transformations to incrementally get my model to final destination.|
The initial plan is to use a simple mechanism to preserve these extra information but eventually I want to expand on this idea and create what I am calling now "reusable annotations":
A. store extra information (it can be Annotation or Tag) outside of main model, so when model is regenerated, extra information is not lost
B. merge back extra information after original model is regenerated (granted I MUST address dangling cross references)
C. add flexibility to reuse extra information for a specific EObject to a category of EObjects based on a Query instead of simple cross reference. I understand, this option is more complicated and it may end with an Aspect Oriented Modelling approach. In this case, href is basically replaced by a query and weave the two models using these queries to find model elements to apply Annotations/Tags.
The reason behind #C: if I add some Annotations/Tags to an element of type Service, I want to reuse the same set of Annotations/Tags for all Services based on specific criteria ( i.e. name of service ends with "DAO" for DataAccessObject pattern or Services which implements a certain Interface).
That's why I am inclined at the moment to go with option #2, export the extra information and later on expand this approach with C.
Powered by FUDForum
. Page generated in 0.01635 seconds