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

Comparing jsr166/src/jdk8/java/util/concurrent/ForkJoinTask.java (file contents):
Revision 1.1 by jsr166, Sat Mar 26 06:22:50 2016 UTC vs.
Revision 1.3 by jsr166, Tue Sep 26 03:44:53 2017 UTC

# Line 63 | Line 63 | import java.util.concurrent.locks.Reentr
63   * encountering the exception; minimally only the latter.
64   *
65   * <p>It is possible to define and use ForkJoinTasks that may block,
66 < * but doing do requires three further considerations: (1) Completion
66 > * but doing so requires three further considerations: (1) Completion
67   * of few if any <em>other</em> tasks should be dependent on a task
68   * that blocks on external synchronization or I/O. Event-style async
69   * tasks that are never joined (for example, those subclassing {@link
# Line 1343 | Line 1343 | public abstract class ForkJoinTask<V> im
1343          public final void setRawResult(T v) { result = v; }
1344          public final boolean exec() { runnable.run(); return true; }
1345          public final void run() { invoke(); }
1346 +        public String toString() {
1347 +            return super.toString() + "[Wrapped task = " + runnable + "]";
1348 +        }
1349          private static final long serialVersionUID = 5232453952276885070L;
1350      }
1351  
# Line 1360 | Line 1363 | public abstract class ForkJoinTask<V> im
1363          public final void setRawResult(Void v) { }
1364          public final boolean exec() { runnable.run(); return true; }
1365          public final void run() { invoke(); }
1366 +        public String toString() {
1367 +            return super.toString() + "[Wrapped task = " + runnable + "]";
1368 +        }
1369          private static final long serialVersionUID = 5232453952276885070L;
1370      }
1371  
# Line 1405 | Line 1411 | public abstract class ForkJoinTask<V> im
1411              }
1412          }
1413          public final void run() { invoke(); }
1414 +        public String toString() {
1415 +            return super.toString() + "[Wrapped task = " + callable + "]";
1416 +        }
1417          private static final long serialVersionUID = 2838392045355241008L;
1418      }
1419  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines