public final class ExecutorServiceHelper extends Object
| 构造器和说明 |
|---|
ExecutorServiceHelper() |
| 限定符和类型 | 方法和说明 |
|---|---|
static boolean |
shutdownAndAwaitTermination(ExecutorService pool) |
static boolean |
shutdownAndAwaitTermination(ExecutorService pool,
long timeoutMillis)
The following method shuts down an
ExecutorService in two
phases, first by calling shutdown to reject incoming tasks,
and then calling shutdownNow, if necessary, to cancel any
lingering tasks. |
public static boolean shutdownAndAwaitTermination(ExecutorService pool)
public static boolean shutdownAndAwaitTermination(ExecutorService pool, long timeoutMillis)
ExecutorService in two
phases, first by calling shutdown to reject incoming tasks,
and then calling shutdownNow, if necessary, to cancel any
lingering tasks.Copyright © 2021. All rights reserved.