0

I would like to extend the GUI functionality of an existing RCP application with another plug-in.

One approach would be to use a fragment which is described quite well in this tutorial.

I tried it, and everything seems to work fine. When I build the project, I get a separate jar for the extension plugin.

Now to my question: can I safely add/remove this jar from the application to add/remove the desired functionality? Is this a good way to do this, or would you say that another approach works better?

greg-449
  • 109,219
  • 232
  • 102
  • 145
user3726374
  • 583
  • 1
  • 4
  • 24

1 Answers1

0

You should be able to add the plugin OK.

If you just delete the plugin to remove it then you would have to restart Eclipse specifying the -clean and -clearPersistedState options to clean things up.

If the RCP you are extending includes the Eclipse p2 install manager you could create an update site so that the plugin can be installed 'properly' see http://www.vogella.com/tutorials/EclipsePlugIn/article.html#p2deployplugin

greg-449
  • 109,219
  • 232
  • 102
  • 145
  • Well, let's say the RCP should be very small (e.g. only containing an "About" menu). When I build this with maven, I get the actual application and a jar file for the extension plug-in. When the extension jar is present, I see another menu, and when I remove it the menu is gone. Could you specify what clean up I would need to do? – user3726374 Aug 12 '14 at 16:48
  • You have to use the -clean and -clearPersistedState options to clean up Eclipse internal data structures, these will be present regardless of the size of the RCP – greg-449 Aug 12 '14 at 17:26