Skip to content
  Projet Triskell  

Creating a New Input Meta-model (Optional)

Document Actions
This section describes the creation of a new input meta-model (if needed) to describe an input domain.

Steps to create a new meta-model

1. Let us assume that we want to create a new meta-model in the resource directory : "platform:/resource/Pramana/demo/Sample/input/metamodel"

2. Right click on the directory "metamodel" and go to : New->Other and Left-click

3. Go to Ecore Tools -> Ecore Diagram and Left-click on Next

4. Choose a name for the meta-model in ecore format and click on Finish. Let us call the meta-model default.ecore and its diagram default.ecoredi

5. You have screen that allows you create a class diagram representing your input domain:


6. Once, you have created your input meta-model we need to transform the corresponding ecore file to a common format called Kermeta.

7. Right click on the Ecore file default.ecore representing the meta-model and go to Kermeta->Generate Kermeta Source (=>kmt)

8. Add Kermeta invariants if necessary to the default.kmt file. Kermeta also have a prototype transformation of OCL constraints to Kermeta invariants. See Kermeta Reference Manual.

9. Generate a Kermeta model file default.km representing an XML version of the meta-model. Right click on default.kmt file go to Kermeta->Compile to Kermeta model and Left Click

10. We now have an input domain defined in the file default.km. This file is used as input to the Pramana transformation.