Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [henshin-dev] Problem with enums and registered packages

Hi Jonathan,

I have not tried it out yet. It should actually work if you use foo as attribute value (no matter how you register your package). Henshin should actually avoid using the _javascript_ engine in your case. I don't know why it is using _javascript_. Anyway, the problem is that in the _javascript_ engine, the enum constants are not visible. What should work though is if you use the string "foo" instead of foo (with quotes!). The interpreter should automatically convert this string into the correct enum constant. Does that work?

Am 2/1/2013 5:56 PM, schrieb Jonathan Brachthäuser:
My question pointed to the usage of my EPackage inside of henshin (in the model / diagram files). In the context menu of the Module I can select "Import Package ... from Registry", but I don't know how to register my package in the current eclipse runtime (Other than exporting it to Dropins / Starting a second plugin-runtime) in order to be able to select it from the list.

Exporting a package in the current run-time is not supported on purpose. If you want to use dynamic EMF, you should import a package from the workspace. If you want to use a generated model, you should use the registry. In this case, you will need 2 Eclipse instances. There are some ways to combine dynamic and static EMF. You can take a look at the method HenshinResourceSet.getModule() with the fixImports parameter. But in general, I would rather recommend to go only with either dynamic or static EMF.

Hope that helps.

Cheers,
Christian


Thank you very much


Jona


_______________________________________________
henshin-dev mailing list
henshin-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/henshin-dev


Back to the top