Java线程池中submit()和execute之间的区别?

一: submit()方法,能够提供Future < T > 类型的返回值。 executor()方法,无返回值。html execute无返回值java public void execute(Runnable command) { if (command == null) throw new NullPointerException();//抛掉异常 int c = ctl.get(); if
相关文章
相关标签/搜索