diff options
author | Todor Boev | 2017-10-02 16:06:00 +0000 |
---|---|---|
committer | Todor Boev | 2017-10-04 13:26:14 +0000 |
commit | 1c02b17b8348fc8a3e04a05db1240a28ecc352cf (patch) | |
tree | ed7666b5190cdd77cbb2d9859396b5a19a0c79a8 /bundles/org.eclipse.equinox.p2.publisher | |
parent | 719079bb53131a19435e345b0e58228dedb75dbc (diff) | |
download | rt.equinox.p2-1c02b17b8348fc8a3e04a05db1240a28ecc352cf.tar.gz rt.equinox.p2-1c02b17b8348fc8a3e04a05db1240a28ecc352cf.tar.xz rt.equinox.p2-1c02b17b8348fc8a3e04a05db1240a28ecc352cf.zip |
Bug 313553 - Unentangle ProvidedCapability members and attributes
The members are the generic way for p2 queries to describe getters
on objects. The capability attributes then participate in queries
as the "attributes" member of a ProvidedCapability object.
Fixed the IProvidedCapability to follow the OSGi convention that the
attributes contain the name of the capability under a key equal to the
capability namespace. This is cleaner than to introduce a new "name"
attribute for the p2 name that can conflict with an incoming OSGi "name"
attribute.
Fixed the version of IProvidedCapability to follow the OSGi convention
that capabilities with a version have a "version" attribute with a value
of type an OSGi version object.
Change-Id: Ic9b77c2d103216141035dc3fb5861ca99a3ddccd
Signed-off-by: Todor Boev <rinsvind@gmail.com>
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.publisher')
-rw-r--r-- | bundles/org.eclipse.equinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/actions/JREAction.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/bundles/org.eclipse.equinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/actions/JREAction.java b/bundles/org.eclipse.equinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/actions/JREAction.java index baacf2e3b..26a1b0da3 100644 --- a/bundles/org.eclipse.equinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/actions/JREAction.java +++ b/bundles/org.eclipse.equinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/actions/JREAction.java @@ -41,6 +41,7 @@ public class JREAction extends AbstractPublisherAction { private static final String PROFILE_SYSTEM_PACKAGES = "org.osgi.framework.system.packages"; //$NON-NLS-1$ public static final String NAMESPACE_OSGI_EE = "osgi.ee"; //$NON-NLS-1$ + public static final String VERSION_OSGI_EE = "version"; //$NON-NLS-1$ private File jreLocation; private String environment; @@ -224,7 +225,7 @@ public class JREAction extends AbstractPublisherAction { // complete record -> store Map<String, Object> capAttrs = new HashMap<>(); capAttrs.put(NAMESPACE_OSGI_EE, eeName); - capAttrs.put("version", parsedVersion); //$NON-NLS-1$ + capAttrs.put(VERSION_OSGI_EE, parsedVersion); parsingResult.add(MetadataFactory.createProvidedCapability(NAMESPACE_OSGI_EE, capAttrs)); |