Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » Get required plugins
Get required plugins [message #79288] Sun, 17 December 2006 10:52 Go to next message
Eclipse UserFriend
Originally posted by: dastoaster.web.de

Hi!

Is there an easy way to get the required plugins/bundles (or names and
versions of them) of a plugin/bundle?
P.e. in the eclipse-ide you can push the "required plugins"-button at the
launch configuration of a plugin to compute only the necessary bundles.
Can I use this mechanism in my own standalone rcp application without
implementing it for myself?

Thanks!

DasToaster
Re: Get required plugins [message #79421 is a reply to message #79288] Mon, 18 December 2006 16:43 Go to previous messageGo to next message
Thomas Watson is currently offline Thomas WatsonFriend
Messages: 503
Registered: July 2009
Senior Member
In OSGi there is a service org.osgi.service.packageadmin.PackageAdmin.
This OSGi service can be used to get bundle dependencies. I find this
service very cumbersome though. For example, you can get all the
available bundles and exported packages and then see who depends on
them. But it is pretty hard to use PackageAdmin to find out what a
particular bundle depends on.

In Equinox we have another service that exposes the resolver state used
by the framework (org.eclipse.osgi.service.resolve.PlatformAdmin). You
can use PlatformAdmin to get a resolver State. The State holds
BundleDescription objects which represent each Bundle installed in the
Framework. The BundleDescription object can be used to get all the
dependencies for a bundle. There is also a useful class StateHelper
that can be used to get all visible packages for a particular bundle.

The PlatformAdmin service is used by PDE and others to model an OSGi
framework.

HTH

Tom
Re: Get required plugins [message #79926 is a reply to message #79421] Wed, 27 December 2006 21:43 Go to previous message
Eclipse UserFriend
Originally posted by: slewis.composent.com

Hi Tom,

Tom Watson wrote:
> In OSGi there is a service org.osgi.service.packageadmin.PackageAdmin.
> This OSGi service can be used to get bundle dependencies. I find this
> service very cumbersome though. For example, you can get all the
> available bundles and exported packages and then see who depends on
> them. But it is pretty hard to use PackageAdmin to find out what a
> particular bundle depends on.
>
> In Equinox we have another service that exposes the resolver state used
> by the framework (org.eclipse.osgi.service.resolve.PlatformAdmin). You
> can use PlatformAdmin to get a resolver State. The State holds
> BundleDescription objects which represent each Bundle installed in the
> Framework. The BundleDescription object can be used to get all the
> dependencies for a bundle. There is also a useful class StateHelper
> that can be used to get all visible packages for a particular bundle.
>
> The PlatformAdmin service is used by PDE and others to model an OSGi
> framework.

In searching through the eclipse 3.3m4 source the only *.pde.* reference
I found to PlatformAdmin was in org.eclipse.pde.internal.core.PDECore
(the Activator for the org.eclipse.ecf.pde.core bundle)...and the
acquirePlatform() method in PDECore doesn't seem to be used anywhere
else in pde.

Maybe this is a message more suitable for pde-build-dev, but are there
more/other pointers to PDE example usage (or other usage) of
PlatformAdmin/State that would be easy to point to?

thanksinadvance,

Scott
Previous Topic:ClassLoader deadlock issues
Next Topic:Tomcat servlet interaction with Eclipse
Goto Forum:
  


Current Time: Sat Apr 27 00:17:41 GMT 2024

Powered by FUDForum. Page generated in 0.02782 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top