How to include a OSGI PlugIn into an Eclipse Project - java

I'm using Eclipse Luna (64Bit) and I have to develop a System, which can manage several Plug-In's. The Plug-In's must be included at Runtime dynamically and I've read, that it is possible to do this with the OSGi-Framework. In Eclipse I started to implement some Example Plugin-Projects and now I want to include them into an another Eclipse Java-Project but thats over my head till now.
Is there a solution for this problem anyway or do I have to use another Framework?
Thanks for all answers!

Are you trying to write a plug-in for Eclipse or create your own plugin management system? If the latter, I'd suggest that you use OSGi as the basis instead of re-inventing the wheel. There's lots of good documentation on the 'net about how to do that.

Related

Use eclipse compare tool built-in in plugin

I'm trying to develop a plugin in Java for Eclipse. For this, I want to use the built-in tool used for comparing files.
I found some help in eclipse wiki (https://wiki.eclipse.org/FAQ_How_do_I_create_a_compare_editor%3F) but it seems not enougth for a developpement since there are lot of empties in explanation.
I also found this but there is no implementation or use sample to understand how it's work.
What I want is to show the compare tool view inside a plugin to manage some merges in a list of files.
I'm currently work on Neon.1 Release (4.6.1) of Eclipse on Windows 7 with Java 1.6.
Any kind of help will be apreciate.
Thanks.

Creating Eclipse Projects Programmatically (no Plugin)

I need to create some dummy projects each containing a single class for testing purpose. It seems like the usual way to go is to write an Eclipse plugin for that. However this isn't really the way I want to go, since I have no experience in creating plugins nor do I want to start an extra runtime eclipse Environment. The projects that I want to create should end up in the same workspace I'm currently working in.
So is there any way to achieve such or is writing a plugin the only way to go in that case?
Edit: Again, as far as possible I want to stay away from touching any plugin stuff. Pretty much every solution that i've seen here on Stackoverflow discusses this problem with regards to plugins. So this should (hopefully) not be a duplicate question
You could look at EASE, a scripting environment aimed at Eclipse users. Documentation is quite sparse, but there are some sample scripts aimed at creating projects.

How to handle dual java .jars for Xpages on domino server?

I could need some help.
I want to use Xpages that communicates with java source. Actually I get a problem by importing the ReferencedLibraries of the Java project.
This standalone project has many java packages in use, so I think domino gets trouble by using them.
I'm not sure, but I think it's because there are some libraries/packages twice now.
Once on domino and once in the imported library of the java project.
Has anybody an idea or experience how I could get it work?
Is there a way to find double packages?
Or is domino able to use one of them?
I don't want to proof and deselect every library by hand. That would be a big effort and would not make sense because I have to to it again if the new release of the java project is comming.
Thanks for help.
Importing Java packages is certainly possible. You'd have to provide more details what issues you're seeing.
Domino uses OSGi. So you can use OSGi capabilities, e.g. "exact match" in your dependency definition.
Are you trying to import the libraries into an NSF or as OSGi bundle?

how to integrate a Plug-in Project template into an existing eclipse project?

I have already developped a Java project using Eclipse.
Now I would like to integrate an help system to allow the user to open a guide.
Browsing other questions i found this tutorial to set up Eclipse environment in order to use the Eclipse Help System. Anyway, this tutorial and all documentation I found since now, only explain how to use this system creating a new plugin project.
But what about if I want simply add the help system to an existing Java Project created in Eclipse IDE?
Which step should I follow to update my project configuration?
Is it possible to integrate Eclipse Help system, without using eclipse?
No, the help system you point to is an eclipse plugin based system, useful with RCP programs. See http://wiki.eclipse.org/RCP It will only run in the context of an RCP application.
You might be able to write an RCP app that contains only help, launch it, and communicate with it through http from your java app, but it's not a simple integration ... and you still have to build your help documents so that org.eclipse.ui.help can see them.

How to install OSGi bundle in program distribution

I have an application that I am converting to OSGi, and there are a couple of
bundles that are required (for now). These are jars that are included in the
program distribution. What is the best way to install these? I was looking
at using a classpath:xxx.jar, but is there a better way to do this?
thanks,
Lance
I'm guessing that you want an easy way to start up your application, without having to install all bundles from the console at every startup. If that is your current problem, you can take a look at
http://paxrunner.ops4j.org/space/Pax+Runner , which eases the launching of the framework and deploying the bundles into it, or
http://njbartlett.name/bndtools.html , an excellent Eclipse plugin that helps you during development.
Another approach that could be satisfying is to create a feature containing all your bundles. See for a hint here. A feature is a package of bundles and it allows you to install a bunch of bundles with one command.

Categories