[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [equinox-dev] Way to retrieve the bundles with provides a capability from BundleRequirement

This is all getting a bit fuzzy for me because PDE is still using the old Equinox resolver API which the framework no longer actually uses at runtime.  But if I recall correctly Require-Capability reqs are modelled with the org.eclipse.osgi.service.resolver.GenericSpecification interface which has a getSuppliers() method.  The reason for it being plural is because require-capability may specify a cardinality of multiple so they can be 'wired' to more than one supplier at a time.  Also see org.eclipse.osgi.service.resolver.BundleDescription.getGenericRequires()



From:        Lars Vogel <lars.vogel@xxxxxxxxxxx>
To:        Equinox development mailing list <equinox-dev@xxxxxxxxxxx>
Date:        12/20/2016 07:54 AM
Subject:        [equinox-dev] Way to retrieve the bundles with provides a        capability from BundleRequirement
Sent by:        equinox-dev-bounces@xxxxxxxxxxx

Friends of Equinox,

in PDE we have this "Add required" button which allows adding the
bundle requirements to a launch configuration and the product.

Currently is is implemented for required bundles and imported
packages. Equinox provides very simple API for that:

BundleSpecification requiredBundle;
BaseDescription bd = requiredBundle.getSupplier();

Do you have something similar for retrieving the bundles which
provides a capability (provide-capability)?

I found BundleRequirement but see now way to retrieve bundles which
seems to model "require-capability" but was unable to determine the
API to find suppliers.

Best regards, Lars

Eclipse Platform UI and e4 project co-lead
CEO vogella GmbH

Haindaalwisch 17a, 22395 Hamburg
Amtsgericht Hamburg: HRB 127058
Geschäftsführer: Lars Vogel, Jennifer Nerlich de Vogel
USt-IdNr.: DE284122352
Fax (040) 5247 6322, Email: lars.vogel@xxxxxxxxxxx, Web:
equinox-dev mailing list
To change your delivery options, retrieve your password, or unsubscribe from this list, visit