tags:

views:

65

answers:

2

Both of those frameworks deal with meta-model:

Do you have example of practical applications based on meta-model transformation with those tools?

A: 

They are different in term of document storing the metamodel.

Regarding XText, this article illustrates one usage, when it comes to y create your own programming languages and domain-specific languages (DSLs).

Once you have a language, you want to process it and this means usually to transform your model into another representation.
The facility responsible for this transformation is called generator and consists of a bunch of transformation templates (e.G. XPand) and some code executing them. On some event, the model is read in and the transformations are applied to produce code.

Example of such a model transformation:

dot3zest, which comes with a DOT to Zest interpreter (which now uses the Xtext switch API generated for the DOT grammar) is support for ad-hoc DOT edge definitions.

alt text


Regarding MPS, you have here a serie of practical examples,
like this code generation to GPL such as Java, C#, C++ or XML:

alt text

VonC
Note: a [conference in October 2010](http://www.voelter.de/conferences/index/detail803128037.html) will illustrate a practical example with both frameworks. For the differences, see [also here](http://lambda-the-ultimate.org/node/3994#comment-60524)
VonC
Is the code generation the ultimate goal or I am not seeing it far enough?
S.R
@S.R: no the ultimate goal remains model transformation. You transform an AST (abstract syntaxt tree) into another, and that will give you: code (code generation), or nodes (the node graph in the first examples), or any other AST which will represent whatever the destination model is supposed to.
VonC
+3  A: 

We created whole bug tracker using MPS. Code generation is not the goal but mean to get some executable code. The goal is to give a tool to developer that allows creating DSLs with minimum effort.

Cool thing about MPS is that it also provides you with an IDE for your language. And different DSLs you create are compatible, i.e. you can create DSL that extends Java with closures and another DSL that enables external methods, and these extensions will work together.

Maxim Mazin