Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEike Stepper2014-07-02 07:07:30 -0400
committerPascal Rapicault2015-02-02 10:37:41 -0500
commit045d698f5769d110f20411cbdd2b91664337f97d (patch)
tree2fed6c03d38e67bd784a133d845c19d1ed467522 /bundles/org.eclipse.equinox.p2.engine/src
parent6cf7e98bd1fe3001279ba1bde421be18fc457a39 (diff)
downloadrt.equinox.p2-045d698f5769d110f20411cbdd2b91664337f97d.tar.gz
rt.equinox.p2-045d698f5769d110f20411cbdd2b91664337f97d.tar.xz
rt.equinox.p2-045d698f5769d110f20411cbdd2b91664337f97d.zip
Bug 438714 - Expose whether a provisioning plan has operands or notI20150210-0800I20150203-0800
This change adds a public isEmpty() method to IProvisioningPlan. Change-Id: Ib1eef3c306f524bc542cca0885b9b7e32c90d8a9 Signed-off-by: Eike Stepper <stepper@esc-net.de>
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.engine/src')
-rw-r--r--bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ProvisioningPlan.java4
-rw-r--r--bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/IProvisioningPlan.java7
2 files changed, 11 insertions, 0 deletions
diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ProvisioningPlan.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ProvisioningPlan.java
index 992f4adaa..7703e3a67 100644
--- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ProvisioningPlan.java
+++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ProvisioningPlan.java
@@ -68,6 +68,10 @@ public class ProvisioningPlan implements IProvisioningPlan {
return operands.toArray(new Operand[operands.size()]);
}
+ public boolean isEmpty() {
+ return operands.isEmpty();
+ }
+
/* (non-Javadoc)
* @see org.eclipse.equinox.p2.engine.IProvisioningPlan#getRemovals()
*/
diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/IProvisioningPlan.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/IProvisioningPlan.java
index 2493b85fd..a6ca379ab 100644
--- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/IProvisioningPlan.java
+++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/IProvisioningPlan.java
@@ -91,6 +91,13 @@ public interface IProvisioningPlan {
public IStatus getStatus();
/**
+ * Returns <code>true</code> if the plan contains no operations, <code>false</code> otherwise.
+ *
+ * @return <code>true</code> if the plan contains no operations, <code>false</code> otherwise.
+ */
+ public boolean isEmpty();
+
+ /**
* Adds an installable unit to the plan. This will cause the given installable unit
* to be installed into the profile when this plan is executed by the engine.
* <p>

Back to the top