When you say "as a model under the name "JavaModel"", what do you mean
exactly? The model you have is a metamodel, so you should not add it as
a model directly to your launch configuration. Instead, you need to add
a model using the label JavaModel and ensure that the metamodel of that
is the JavaModel metamodel.
On 11/07/2011 18:22, Federico Tomassetti wrote:
> I tried loading the JavaModel package both as a Registered meta-model
> and as a model under the name "JavaModel". It did not work.
Federico: oops, seems I misread your first message.
If you load a registered EPackage as a model, you are loading an Ecore model, which contains your metamodel. The only types you can work with are EClass, EAttribute and so on: the Ecore types.
If you want to use the JavaModel EPackage to create a model, you need to load a proper model based on your metamodel. You can add an empty model to a launch configuration by setting the "Read on load" option to false.
By the way, have you checked our examples? This one should be useful: