Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How create Java code from Ecore metamodel without EMF jar dependences?

Is possible to generate Java code from an Ecore metamodel, without the dependencies of EMF? Generate "clean Code" as if it were a generation from a UML model.

like image 709
seeebown Avatar asked Dec 06 '25 10:12

seeebown


1 Answers

The easy way is to set the GenModel option "Suppress EMF Types" in the "Model Feature Defaults" section of the top-level node... There are are hole set of relevant options. Refer to the EMF book (2nd edition), for the complete details.

You can also use JET to generate you own Java code from the ECore model. Have a look at "Metamodeling with EMF: Generating concrete, reusable Java snippets" for a rather detailed description.

like image 172
Tonny Madsen Avatar answered Dec 08 '25 23:12

Tonny Madsen