[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [p2-dev] Expressing complex requirements (while processing droplets)

You will need to a create a Or expression. 
You can find something similar to this in the class called RequestFlexer method createORRequirement

-----Original Message-----
From: p2-dev-bounces@xxxxxxxxxxx [mailto:p2-dev-bounces@xxxxxxxxxxx] On Behalf Of Krzysztof Daniel
Sent: July-01-13 6:13 AM
To: p2-dev
Subject: [p2-dev] Expressing complex requirements (while processing droplets)

Hey P2 masters,

A droplet requires all bundles to be installed from a certain location.
But it may happen that two location provide the same plugin, which is a singleton, so only one could be installed.
I'd like to overcome this problem by creating a fake installation unit which would be installed if any instance of a bundle would, f.e.:
let's assume that there are two droplets (1 & 2) providing javax.xml_1.3.4.jar. So while processing those droplets, I'd like to create a unit common_javax_xml_1.3.4 requiring javax.xml from droplet 1 or from droplet 2, and then make droplet 1 and droplet 2 depend on
common_javax_xml_1.3.4 rather than on javax.xml single instance.

How to properly translate this into p2 requirements? 

Krzysztof Daniel <kdaniel@xxxxxxxxxx>
Red Hat

p2-dev mailing list