Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Arthorne2008-10-30 14:50:29 +0000
committerJohn Arthorne2008-10-30 14:50:29 +0000
commitd880852167bfca9b5095443806d4bdc8701f1151 (patch)
treedce670f3925c6ca4ea8c4903a92791703104947a
parent3314c79be64cd486566dd286ef98e799253e0785 (diff)
downloadrt.equinox.p2-d880852167bfca9b5095443806d4bdc8701f1151.tar.gz
rt.equinox.p2-d880852167bfca9b5095443806d4bdc8701f1151.tar.xz
rt.equinox.p2-d880852167bfca9b5095443806d4bdc8701f1151.zip
Added javadoc
-rw-r--r--bundles/org.eclipse.equinox.p2.updatechecker/src/org/eclipse/equinox/internal/provisional/p2/updatechecker/IUpdateChecker.java31
1 files changed, 30 insertions, 1 deletions
diff --git a/bundles/org.eclipse.equinox.p2.updatechecker/src/org/eclipse/equinox/internal/provisional/p2/updatechecker/IUpdateChecker.java b/bundles/org.eclipse.equinox.p2.updatechecker/src/org/eclipse/equinox/internal/provisional/p2/updatechecker/IUpdateChecker.java
index a343d7858..98bf64c35 100644
--- a/bundles/org.eclipse.equinox.p2.updatechecker/src/org/eclipse/equinox/internal/provisional/p2/updatechecker/IUpdateChecker.java
+++ b/bundles/org.eclipse.equinox.p2.updatechecker/src/org/eclipse/equinox/internal/provisional/p2/updatechecker/IUpdateChecker.java
@@ -13,7 +13,7 @@ package org.eclipse.equinox.internal.provisional.p2.updatechecker;
import org.eclipse.equinox.internal.provisional.p2.query.Query;
/**
- * An UpdateChecker periodically polls for updates to specified profiles and
+ * An update checker periodically polls for updates to specified profiles and
* informs listeners if updates are available. Listeners may then determine
* whether to retrieve the updates, inform the user, etc.
*/
@@ -21,8 +21,37 @@ public interface IUpdateChecker {
public static final String SERVICE_NAME = IUpdateChecker.class.getName();
public static long ONE_TIME_CHECK = -1L;
+ /**
+ * Adds an update listener that will be notified when updates are available for all
+ * installable units that satisfy the given query. The listener will remain
+ * registered until removed using the {@link #removeUpdateCheck(IUpdateListener)}
+ * method. Adding a listener that is identical to a listener that is already registered
+ * has no effect.
+ * <p>
+ * Once the listener is registered, it will continue to receive notification of updates
+ * based on the specified polling frequency. However, if a delay value of {@link #ONE_TIME_CHECK}
+ * is used, only a single update check will occur for that listener. If this delay value
+ * is used, the specified polling frequency is ignored.
+ *
+ * @param profileId The profile id to check for updates
+ * @param iusToCheckQuery An installable unit query that matches the units to check for updates
+ * @param delay The delay in milliseconds before the first query should occur, or {@link #ONE_TIME_CHECK}
+ * to indicate that a single update check should occur immediately
+ * @param poll The polling frequency, in milliseconds, between checks for updates
+ * @param listener The listener to be notified of updates
+ * @see #removeUpdateCheck(IUpdateListener)
+ */
public abstract void addUpdateCheck(String profileId, Query iusToCheckQuery, long delay, long poll, IUpdateListener listener);
+ /**
+ * Removes an update listener from the set of listeners registered with this update
+ * checker. If an update check is currently in progress the listener may still receive
+ * events after this method returns. Removing a listener that is not registered has
+ * no effect.
+ *
+ * @param listener The listener to remove
+ * @see #addUpdateCheck(String, Query, long, long, IUpdateListener)
+ */
public abstract void removeUpdateCheck(IUpdateListener listener);
} \ No newline at end of file

Back to the top