Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMykola Nikishov2018-02-17 09:14:45 +0000
committerMykola Nikishov2018-02-20 08:26:58 +0000
commitc162b8b5afc489c1c59f666de98654134c683605 (patch)
treedd310aff3782334b807d26a9cf3b70a504688570
parentd97bcc18521fdf61df3f9ac6898489463b9cc12e (diff)
downloadrt.equinox.p2-c162b8b5afc489c1c59f666de98654134c683605.tar.gz
rt.equinox.p2-c162b8b5afc489c1c59f666de98654134c683605.tar.xz
rt.equinox.p2-c162b8b5afc489c1c59f666de98654134c683605.zip
Bug 531354 - Restore binary compatibility of publisher.eclipse bundleI20180220-2000
org.eclipse.equinox.p2.publisher.eclipse.BundlesAction is a public not final class exported by publisher.eclipse bundle and there are no restrictions like x-friends, @noextend an alike. This makes it a public API. At binary level, changing signatures [1] of BundlesAction's protected methods is a binary-incompatible change: - remove old methods with first parameter of type ArrayList<IRequirement> - add new methods with the same name but with first parameter of type List<IRequirement> Instead of increasing a major segment of bundle's version, restore binary compatibility by restoring original methods. [1] 02e018c88f5307fc754ae8bc0c0467eb209dd982 Change-Id: I0c5cff87d96c58da45f98d848572271f817364e0 Signed-off-by: Mykola Nikishov <mn@mn.com.ua>
-rw-r--r--bundles/org.eclipse.equinox.p2.publisher.eclipse/src/org/eclipse/equinox/p2/publisher/eclipse/BundlesAction.java12
1 files changed, 11 insertions, 1 deletions
diff --git a/bundles/org.eclipse.equinox.p2.publisher.eclipse/src/org/eclipse/equinox/p2/publisher/eclipse/BundlesAction.java b/bundles/org.eclipse.equinox.p2.publisher.eclipse/src/org/eclipse/equinox/p2/publisher/eclipse/BundlesAction.java
index c2ec094be..e4288b88d 100644
--- a/bundles/org.eclipse.equinox.p2.publisher.eclipse/src/org/eclipse/equinox/p2/publisher/eclipse/BundlesAction.java
+++ b/bundles/org.eclipse.equinox.p2.publisher.eclipse/src/org/eclipse/equinox/p2/publisher/eclipse/BundlesAction.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2008, 2017 Code 9 and others. All rights reserved. This
+ * Copyright (c) 2008, 2018 Code 9 and others. All rights reserved. This
* program and the accompanying materials are made available under the terms of
* the Eclipse Public License v1.0 which accompanies this distribution, and is
* available at http://www.eclipse.org/legal/epl-v10.html
@@ -292,6 +292,11 @@ public class BundlesAction extends AbstractPublisherAction {
return MetadataFactory.createInstallableUnit(iu);
}
+ @Deprecated
+ protected void addImportPackageRequirement(ArrayList<IRequirement> reqsDeps, ImportPackageSpecification importSpec, ManifestElement[] rawImportPackageHeader) {
+ addImportPackageRequirement((List) reqsDeps, importSpec, rawImportPackageHeader);
+ }
+
protected void addImportPackageRequirement(List<IRequirement> reqsDeps, ImportPackageSpecification importSpec, ManifestElement[] rawImportPackageHeader) {
VersionRange versionRange = PublisherHelper.fromOSGiVersionRange(importSpec.getVersionRange());
final boolean optional = isOptional(importSpec);
@@ -305,6 +310,11 @@ public class BundlesAction extends AbstractPublisherAction {
reqsDeps.add(MetadataFactory.createRequirement(PublisherHelper.CAPABILITY_NS_JAVA_PACKAGE, importSpec.getName(), versionRange, null, optional, false, greedy));
}
+ @Deprecated
+ protected void addRequireBundleRequirement(ArrayList<IRequirement> reqsDeps, BundleSpecification requiredBundle, ManifestElement[] rawRequireBundleHeader) {
+ addRequireBundleRequirement((List) reqsDeps, requiredBundle, rawRequireBundleHeader);
+ }
+
protected void addRequireBundleRequirement(List<IRequirement> reqsDeps, BundleSpecification requiredBundle, ManifestElement[] rawRequireBundleHeader) {
final boolean optional = requiredBundle.isOptional();
final boolean greedy;

Back to the top