ExecutorService中几个方法小记(submit/invokeall/excute/shutdown)
public interface ExecutorService extends Executor { //不再接受新任务,待所有任务执行完毕后关闭ExecutorService void shutdown(); //不再接受新任务,直接关闭ExecutorService,返回没有执行的任务列表 List<Runnable> shutdownNow(); //判断ExecutorService是否关闭 boolean.
原创
2021-08-05 15:52:51 ·
543 阅读 ·
0 评论