[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [p2-dev] IRequiredCapability internal?

Personally, I'd like to see an Eclipse API for P2. For Eclipse there are always going to be a few relationships that you are interested in. It would be nice if there was a layer on top of P2 that provided these, with the metaphors used in eclipse.
For instance, I want to open a P2 repository, and get all of the features out of it. Then I want to look at the bundles of the features, or the required features of the features. I shouldn't have to write these queries. As someone using P2 against eclipse, an API that used Eclipse metaphors vs P2 would be much easier to understand.

---------------------------------------------
Marcus Kestler
---------------------------------------------

Inactive hide details for John Arthorne ---03/09/2010 02:10:40 PM---It looks like in the worst case this information can be extJohn Arthorne ---03/09/2010 02:10:40 PM---It looks like in the worst case this information can be extracted from the IRequirement.getMatches()


From:

John Arthorne <arthorne.eclipse@xxxxxxxxx>

To:

P2 developer discussions <p2-dev@xxxxxxxxxxx>

Date:

03/09/2010 02:10 PM

Subject:

Re: [p2-dev] IRequiredCapability internal?

Sent by:

p2-dev-bounces@xxxxxxxxxxx




It looks like in the worst case this information can be extracted from the IRequirement.getMatches() object by copying the helper methods extractNamespace, extractName, and extractRange from the RequiredCapability class. That would allow you to get the information while only accessing API methods.

However, if we know that *some* requirements can be expressed in the form namespace/name/range, then I'm not sure why we don't offer an API such as IRequiredCapability to obtain that information. That doesn't prevent us from having more general or specialized forms of requirements that are *not* represented as IRequiredCapability. If you have an IU that is known to be an OSGi bundle, then it seems reasonable to want to be able to introspect the metadata to find out things like the bundle/package imports via the p2 metadata API. I'm quite possibly missing something here though...

John


On Tue, Mar 9, 2010 at 12:15 PM, Thomas M Houser <tmhouser@xxxxxxxxxx> wrote: _______________________________________________
p2-dev mailing list
p2-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/p2-dev


GIF image

GIF image