Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPascal Rapicault2011-06-10 23:15:42 +0000
committerPascal Rapicault2011-06-10 23:15:42 +0000
commit8877f6b1ffe5afc105a50cc34b9cc07d8383fad9 (patch)
tree71081e88d485642b76d903f8140ff1977347e4bd /bundles/org.eclipse.equinox.p2.operations
parent184a45ad56706cdfd2d7644aba58bfb580397ab4 (diff)
downloadrt.equinox.p2-8877f6b1ffe5afc105a50cc34b9cc07d8383fad9.tar.gz
rt.equinox.p2-8877f6b1ffe5afc105a50cc34b9cc07d8383fad9.tar.xz
rt.equinox.p2-8877f6b1ffe5afc105a50cc34b9cc07d8383fad9.zip
Bug 348981 & Bug 348982 - Tweak to the API
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.operations')
-rw-r--r--bundles/org.eclipse.equinox.p2.operations/META-INF/MANIFEST.MF2
-rw-r--r--bundles/org.eclipse.equinox.p2.operations/src/org/eclipse/equinox/p2/operations/OperationFactory.java23
2 files changed, 13 insertions, 12 deletions
diff --git a/bundles/org.eclipse.equinox.p2.operations/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.operations/META-INF/MANIFEST.MF
index acddd86dc..5d72f5d83 100644
--- a/bundles/org.eclipse.equinox.p2.operations/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.equinox.p2.operations/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.equinox.p2.operations;singleton:=true
-Bundle-Version: 2.1.0.qualifier
+Bundle-Version: 2.1.100.qualifier
Bundle-Activator: org.eclipse.equinox.internal.p2.operations.Activator
Bundle-Vendor: %providerName
Bundle-Localization: plugin
diff --git a/bundles/org.eclipse.equinox.p2.operations/src/org/eclipse/equinox/p2/operations/OperationFactory.java b/bundles/org.eclipse.equinox.p2.operations/src/org/eclipse/equinox/p2/operations/OperationFactory.java
index cc28e0c53..599eadfce 100644
--- a/bundles/org.eclipse.equinox.p2.operations/src/org/eclipse/equinox/p2/operations/OperationFactory.java
+++ b/bundles/org.eclipse.equinox.p2.operations/src/org/eclipse/equinox/p2/operations/OperationFactory.java
@@ -50,7 +50,7 @@ public class OperationFactory {
}
//Return a list of IUs from the list of versionedIDs originally provided
- private Collection<IInstallableUnit> gatherIUs(IQueryable<IInstallableUnit> searchContext, Collection<IVersionedId> ius, boolean checkIUs, IProgressMonitor monitor) throws ProvisionException {
+ private Collection<IInstallableUnit> gatherIUs(IQueryable<IInstallableUnit> searchContext, Collection<? extends IVersionedId> ius, boolean checkIUs, IProgressMonitor monitor) throws ProvisionException {
Collection<IInstallableUnit> gatheredIUs = new ArrayList<IInstallableUnit>(ius.size());
for (IVersionedId versionedId : ius) {
@@ -83,11 +83,11 @@ public class OperationFactory {
/**
* This factory method creates an {@link InstallOperation} to install all the elements listed from the specified repositories.
* @param toInstall the elements to install. This can not be null.
- * @param repos the repositories to install the elements from.
+ * @param repos the repositories to install the elements from. If null is passed, it will use all previously registered repositories.
* @param monitor the progress monitor
* @return an operation to install
*/
- public InstallOperation createInstallOperation(Collection<IVersionedId> toInstall, Collection<URI> repos, IProgressMonitor monitor) throws ProvisionException {
+ public InstallOperation createInstallOperation(Collection<? extends IVersionedId> toInstall, Collection<URI> repos, IProgressMonitor monitor) throws ProvisionException {
Assert.isNotNull(toInstall);
IProvisioningAgent agent = getAgent();
@@ -105,11 +105,11 @@ public class OperationFactory {
/**
* Create an {@link UninstallOperation} that will uninstall the listed elements from the running instance.
* @param toUninstall the elements to uninstall. This can not be null.
- * @param repos the repositories to install the elements from. Passing null will
+ * @param repos the repositories to install the elements from. If null is passed, it will use all previously registered repositories.
* @param monitor the progress monitor
* @return an operation to uninstall
*/
- public UninstallOperation createUninstallOperation(Collection<IVersionedId> toUninstall, Collection<URI> repos, IProgressMonitor monitor) throws ProvisionException {
+ public UninstallOperation createUninstallOperation(Collection<? extends IVersionedId> toUninstall, Collection<URI> repos, IProgressMonitor monitor) throws ProvisionException {
Assert.isNotNull(toUninstall);
IProvisioningAgent agent = getAgent();
ProvisioningContext ctx = createProvisioningContext(repos, agent);
@@ -138,12 +138,13 @@ public class OperationFactory {
/**
* Create an {@link UpdateOperation} that will update the elements specified.
- * @param toUpdate
- * @param repos
- * @param monitor
+ * @param toUpdate The elements to update.Passing null will result in looking for an update to all the installed. Note that you can pass the results of {@link OperationFactory.listInstalledElements} to this
+ * method if you wish to update all elements installed in the running instance of eclipse.
+ * @param repos the repositories to update the elements from. If null is passed, it will use all previously registered repositories.
+ * @param monitor the progress monitor
* @return an instance of {@link UpdateOperation}
*/
- public UpdateOperation createUpdateOperation(Collection<IVersionedId> toUpdate, Collection<URI> repos, IProgressMonitor monitor) throws ProvisionException {
+ public UpdateOperation createUpdateOperation(Collection<? extends IVersionedId> toUpdate, Collection<URI> repos, IProgressMonitor monitor) throws ProvisionException {
IProvisioningAgent agent = getAgent();
ProvisioningContext ctx = createProvisioningContext(repos, agent);
@@ -158,11 +159,11 @@ public class OperationFactory {
/**
* This factory method creates an {@link SynchronizeOperation} that will cause the current installation to exclusively contain the elements listed once executed.
* @param toInstall the elements to install. This can not be null.
- * @param repos the repositories to install the elements from.
+ * @param repos the repositories to install the elements from. If null is passed, it will use all previously registered repositories.
* @param monitor the progress monitor
* @return an instance of {@link SynchronizeOperation}.
*/
- public SynchronizeOperation createSynchronizeOperation(Collection<IVersionedId> toInstall, Collection<URI> repos, IProgressMonitor monitor) throws ProvisionException {
+ public SynchronizeOperation createSynchronizeOperation(Collection<? extends IVersionedId> toInstall, Collection<URI> repos, IProgressMonitor monitor) throws ProvisionException {
IProvisioningAgent agent = getAgent();
ProvisioningContext ctx = createProvisioningContext(repos, agent);

Back to the top