|
Re: Using an External API with EMF [message #1780634 is a reply to message #1780622] |
Thu, 25 January 2018 06:55 |
Ed Merks Messages: 33137 Registered: July 2009 |
Senior Member |
|
|
Any jar can be easily wrapped in a bundle so that PDE can manage the classpath. But EMF also works stand-alone, so you can manage the classpath like you do for any "normal" (non-PDE nature) Java project. And you can tell the GenModel to stop generating the MANIFEST.MF, plugin.xml or updating the .classpath, i.e., Update Classpath false. But personally I think it is far easier if you wrap your jar dependencies in a plugin. Just use the wizard to create a new Plug-in project, create a folder, e.g., lib, put all your *.jars in there, open the MANIFEST.MF, and on the Runtime tab use the Classpath section to Add... the jars in the lib folder, and then use the Exported Packages to list packages in those jars that you want visible elsewhere. With this approach you can manage your classpath simply by managing which jars are in the lib folder of the wrapper plugin and it will all be highly portable.
In your model you can use EDataTypes to wrap any Java class or interface and then you can use them in any other parts of your model.
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03327 seconds