摘要:
public class JoinThread { public static void main(String[]args) { Thread o=new OneThread(); o.start(); int index=0; while(true) { System.out.println("main->>"+Thread.cu... 阅读全文
posted @ 2011-09-22 10:59 阳光VIP 阅读(222) 评论(0) 推荐(0)
|
|||
|
摘要:
public class JoinThread { public static void main(String[]args) { Thread o=new OneThread(); o.start(); int index=0; while(true) { System.out.println("main->>"+Thread.cu... 阅读全文
posted @ 2011-09-22 10:59 阳光VIP 阅读(222) 评论(0) 推荐(0)
摘要:
/* 如果我们对某个线程对象在启动(调用start方法)之前调用了setDaemon(true)方法,这个线程就变成了 后台线程.对java程序来说,只要还有一个前台线程在运行,这个进程就不会结束,如果一个进程中只有 后台线程运行,这个进程会结束. */ public class QHThread { public static void main(String[]a... 阅读全文
posted @ 2011-09-22 10:02 阳光VIP 阅读(475) 评论(0) 推荐(0) |
|||