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

Comparing jsr166/src/main/java/util/concurrent/CompletableFuture.java (file contents):
Revision 1.129 by jsr166, Wed Jun 18 04:12:17 2014 UTC vs.
Revision 1.130 by jsr166, Mon Jun 23 21:52:17 2014 UTC

# Line 134 | Line 134 | public class CompletableFuture<T> implem
134       *
135       * * Completion method tryFire(int mode) invokes the associated x
136       *   method with its held arguments, and on success cleans up.
137 <     *   The mode argument allows exec to be called twice (SYNC, then
138 <     *   ASYNC); the first to screen and trap exceptions while
137 >     *   The mode argument allows tryFire to be called twice (SYNC,
138 >     *   then ASYNC); the first to screen and trap exceptions while
139       *   arranging to execute, and the second when called from a
140       *   task. (A few classes are not used async so take slightly
141       *   different forms.)  The claim() callback suppresses function
# Line 162 | Line 162 | public class CompletableFuture<T> implem
162       * is guaranteed not to be observable (i.e., not yet returned or
163       * linked). Multiple threads can call postComplete, which
164       * atomically pops each dependent action, and tries to trigger it
165 <     * via method exec. Triggering can propagate recursively, so exec
166 <     * in NESTED mode returns its completed dependent (if one exists)
167 <     * for further processing by its caller (see method postFire).
165 >     * via method tryFire, in NESTED mode.  Triggering can propagate
166 >     * recursively, so NESTED mode returns its completed dependent (if
167 >     * one exists) for further processing by its caller (see method
168 >     * postFire).
169       *
170       * Blocking methods get() and join() rely on Signaller Completions
171       * that wake up waiting threads.  The mechanics are similar to
# Line 386 | Line 387 | public class CompletableFuture<T> implem
387          return e;
388      }
389  
390 <    // Modes for Completion.exec. Signedness matters.
390 >    // Modes for Completion.tryFire. Signedness matters.
391      static final int SYNC   =  0;
392      static final int ASYNC  =  1;
393      static final int NESTED = -1;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines