by
Lars Vogel / December 9th, 2009
I recently wanted to evolve one of my EMF models. I started writting Java code for translating the EMF model and tweeted about this.
Seems like their are several very good options available for translating EMF models:
Even though ALT and COPE looked very interesting I always wanted to learn how to create my own XSLT style sheets (after all I’m a big Docbook user and David Carver was kind enough to took my XSLT Ant task as a starting point for the Ant task in the Eclipse XSL project).
In addition I believe XSLT can also be handy for me for other transformations in the future
Using XSLT was surprisingly easy. I believe one of the reason are the excellent Eclipse XSL Tools.
I only needed to add a few more hierarchies and to change a tag in my EMF model. In case you are interested I have describe the usage of XSLT for such simple cases here: XSLT with Eclipse XSL Tools – Tutorial.
Thanks to André Dietisheim (@adietisheim), Ian Bull (@irbull),David Carver (@kingargyle), BernhardMerkle (@BernhardMerkle) Michael Kay (@michaelhkay) and Jens von Pilgrim (@jensvp) for their help and advice via twitter.
I recently wanted to evolve one of my EMF models. I started writting Java code for translating the EMF model and tweeted about this.
Seems like their are several very good options available for translating EMF models:
XSLT together with the XSLT Eclipse Project
The Eclipse ATL project
COPE
Even though ALT and COPE looked very interesting I always wanted to learn how to create my own XSLT style sheets (after all I'm a big Docbook user and David Carver was kind enough to took my XSLT Ant task as a starting point for the Ant task in the Eclipse XSL project).
In addition I believe XSLT can also be handy for me for other transformations in the future
Using XSLT was surprisingly easy. I believe one of the reason are the excellent Eclipse XSL Tools.
I only needed to add a few more hierarchies and to change a tag in my EMF model. In case you are interested I have describe the usage of XSLT for such simple cases here: XSLT with Eclipse XSL Tools - Tutorial.
Thanks to André Dietis
Filed under:
Eclipse
You can follow any responses to this entry through the RSS 2.0 feed.
You can leave a response, or trackback from your own site.
December 9th, 2009 at 10:07 am
Hi Lars,
the problem with the XSLT stuff is that you are doing the transformation on the persistence format. This will only work until you are using the (less performant) XML or XMI resources. I’d go with ATL, QVT, Xpand or Cope, depending on your needs…
Bernd
December 9th, 2009 at 2:53 pm
I was puzzled about the meaning of “Eclipse ALT” project. You certainly mean ATL (Atlas Transformation language)
I worked with XSLT for the plain XML transformation and with ATL for the model transformation.
IMHO I would use ATL for dealing with EMF model (instances).
December 9th, 2009 at 4:15 pm
Just a precision: you misspellt “ALT”, in fact it’s ATL (stands for Atlas Transformation Language).
December 9th, 2009 at 4:55 pm
Hi Lars
Feels like model evolution is fated to become a prominent topic…
At Eclipse JWT (Java Workflow Tooling http://eclipse.org/jwt ) we’ve written an ATL-based converter to ease migrating existing models to new versions of our EMF metamodel. Basically, when trying to open an older model, it deduces which ATL transformations have to be applied before being able to open it.
We also do XSL but on very specific topics, however, I didn’t know about COPE.
Maybe an interesting talk topic for the next EclipseCon ?
Regards,
Marc
December 9th, 2009 at 5:16 pm
Sorry for misspelling ATL, I corrected it.
December 11th, 2009 at 10:59 am
Hi,
which XSLT-processor do you use? Do you use XSLT 2.0?
Cheers, Tobias.
December 11th, 2009 at 5:25 pm
@Tobias: The one included in the Eclipse XSL project. Not sure which version this is.
March 30th, 2010 at 8:28 pm
Hi Lars, all
Well, actually talked about metamodel evolution at EclipseCon last week in the end. A not-so-surprising 2/3rd of the room was full and provided interesting questions, even met Sven of the Edapt project proposal that also includes COPE contributions (see http://www.eclipse.org/proposals/edapt/ ).
Session and slides at http://www.eclipsecon.org/2010/sessions/?page=sessions&id=1207
So all in all thanks for helping provide the idea !
Regards,
Marc