ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/main/java/util/concurrent/CompletionService.java
(Generate patch)

Comparing jsr166/src/main/java/util/concurrent/CompletionService.java (file contents):
Revision 1.11 by dl, Thu Sep 8 00:04:00 2005 UTC vs.
Revision 1.12 by jsr166, Wed Sep 14 22:51:10 2005 UTC

# Line 5 | Line 5
5   */
6  
7   package java.util.concurrent;
8 + import java.util.concurrent.*; // for javadoc (till 6280605 is fixed)
9  
10   /**
11   * A service that decouples the production of new asynchronous tasks
# Line 17 | Line 18 | package java.util.concurrent;
18   * in a different part of the program when the reads complete,
19   * possibly in a different order than they were requested.
20   *
21 < * <p>
22 < * Typically, a <tt>CompletionService</tt> relies on a separate {@link
22 < * Executor} to actually execute the tasks, in which case the
21 > * <p>Typically, a <tt>CompletionService</tt> relies on a separate
22 > * {@link Executor} to actually execute the tasks, in which case the
23   * <tt>CompletionService</tt> only manages an internal completion
24   * queue. The {@link ExecutorCompletionService} class provides an
25   * implementation of this approach.
26   *
27 < * <p> Memory consistency effects: State changes to the value returned from
28 < * a <tt>Callable</tt> <a href="package-summary.html#MemoryVisibility"><i>happen-before</i></a>
29 < * actions following a successful return from the corresponding <tt>take()</tt>.
27 > * <p>Memory consistency effects: Actions in a thread prior to
28 > * submitting a task to a {@code CompletionService}
29 > * <a href="package-summary.html#MemoryVisibility"><i>happen-before</i></a>
30 > * actions taken by that task, which in turn <i>happen-before</i>
31 > * actions following a successful return from the corresponding {@code take()}.
32   *
33   */
34   public interface CompletionService<V> {
# Line 43 | Line 45 | public interface CompletionService<V> {
45       */
46      Future<V> submit(Callable<V> task);
47  
46
48      /**
49       * Submits a Runnable task for execution and returns a Future
50       * representing that task.  Upon completion, this task may be

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines