请教一个多线程的问题
public class VerifyQueryThread implements Runnable{
public void run(){
...
}
}
public static void startMutiThread(){
VerifyQueryThread target = new VerifyQueryThread();
for(int j = 0; j < 40;j++){
(new Thread(target)).start();
}
writeLog();
}
我希望writeLog()方法在那40个新开的线程都运行完毕后再执行 应该怎么改写代码? 谢谢