public interface ThreadPool extends Executor
| 限定符和类型 | 方法和说明 |
|---|---|
boolean |
apply(Runnable task) |
default void |
execute(Runnable task) |
int |
getActiveThreadSize() |
long |
getCompletedTaskCount() |
long |
getFailedTaskCount() |
int |
getIdleThreadSize() |
int |
getMaxPoolSize() |
int |
getPoolSize() |
int |
getQueueSize() |
boolean |
isShutdown() |
void |
setRejectedExecutionHandler(RejectedExecutionHandler rejectedExecutionHandler) |
void |
shutdown() |
<R> Promise<R> |
submit(Action<R> action) |
boolean apply(Runnable task)
int getPoolSize()
int getMaxPoolSize()
int getQueueSize()
int getActiveThreadSize()
int getIdleThreadSize()
long getCompletedTaskCount()
long getFailedTaskCount()
boolean isShutdown()
void shutdown()
void setRejectedExecutionHandler(RejectedExecutionHandler rejectedExecutionHandler)
Copyright © 2020. All rights reserved.