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()

HTH

Tom





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



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: [email protected], Web: 
http://www.vogella.com
_______________________________________________
equinox-dev mailing list
[email protected]
To change your delivery options, retrieve your password, or unsubscribe 
from this list, visit
https://dev.eclipse.org/mailman/listinfo/equinox-dev



_______________________________________________
equinox-dev mailing list
[email protected]
To change your delivery options, retrieve your password, or unsubscribe from 
this list, visit
https://dev.eclipse.org/mailman/listinfo/equinox-dev

Reply via email to