12 |
|
import java.util.concurrent.RejectedExecutionException; |
13 |
|
|
14 |
|
/** |
15 |
< |
* A thread managed by a {@link ForkJoinPool}. This class is |
16 |
< |
* subclassable solely for the sake of adding functionality -- there |
17 |
< |
* are no overridable methods dealing with scheduling or execution. |
18 |
< |
* However, you can override initialization and termination methods |
19 |
< |
* surrounding the main task processing loop. If you do create such a |
20 |
< |
* subclass, you will also need to supply a custom {@link |
21 |
< |
* ForkJoinPool.ForkJoinWorkerThreadFactory} to use it in a {@code |
22 |
< |
* ForkJoinPool}. |
15 |
> |
* A thread managed by a {@link ForkJoinPool}, which executes |
16 |
> |
* {@link ForkJoinTask}s. |
17 |
> |
* This class is subclassable solely for the sake of adding |
18 |
> |
* functionality -- there are no overridable methods dealing with |
19 |
> |
* scheduling or execution. However, you can override initialization |
20 |
> |
* and termination methods surrounding the main task processing loop. |
21 |
> |
* If you do create such a subclass, you will also need to supply a |
22 |
> |
* custom {@link ForkJoinPool.ForkJoinWorkerThreadFactory} to use it |
23 |
> |
* in a {@code ForkJoinPool}. |
24 |
|
* |
25 |
|
* @since 1.7 |
26 |
|
* @author Doug Lea |
399 |
|
/** |
400 |
|
* This method is required to be public, but should never be |
401 |
|
* called explicitly. It performs the main run loop to execute |
402 |
< |
* ForkJoinTasks. |
402 |
> |
* {@link ForkJoinTask}s. |
403 |
|
*/ |
404 |
|
public void run() { |
405 |
|
Throwable exception = null; |