5 |
|
*/ |
6 |
|
|
7 |
|
package java.util.concurrent; |
8 |
+ |
import java.util.concurrent.*; // for javadoc |
9 |
|
import java.util.*; |
10 |
|
import java.util.concurrent.atomic.AtomicInteger; |
11 |
|
import java.security.AccessControlContext; |
41 |
|
public class Executors { |
42 |
|
|
43 |
|
/** |
44 |
< |
* Creates a thread pool that reuses a fixed set of threads |
44 |
> |
* Creates a thread pool that reuses a fixed number of threads |
45 |
|
* operating off a shared unbounded queue. At any point, at most |
46 |
|
* <tt>nThreads</tt> threads will be active processing tasks. If |
47 |
|
* additional tasks are submitted when all threads are active, |
60 |
|
} |
61 |
|
|
62 |
|
/** |
63 |
< |
* Creates a thread pool that reuses a fixed set of threads |
63 |
> |
* Creates a thread pool that reuses a fixed number of threads |
64 |
|
* operating off a shared unbounded queue, using the provided |
65 |
|
* ThreadFactory to create new threads when needed. At any point, |
66 |
|
* at most <tt>nThreads</tt> threads will be active processing |