Reputation: 111
I am a beginner in Eclipse EMF. I have created an Ecore metamodel which I want to transform into a new Ecore metamodel in Java that takes into account some characteristics of the first metamodel. I have searched the web but the exlpanations I've found were not clear to me.
How can I get access to the first metamodel from a Java app and how can I generate a new metamodel with the corresponding .ecore and .genmodel files?
Is such a task even possible?
Thanks!
Upvotes: 2
Views: 183
Reputation: 115
You can access in this way :
ResourceSet rs = new ResourceSetImpl();
Resource resource = rs.getResource(URI.createFileURI(metamodelStringURI), true);
Upvotes: 0
Reputation: 576
There is EMF Epsilon language framework which you can use for model transformations. It is written in Java and can be used in java applications. Here is an example.
Upvotes: 0