|
-
Java Thread
A very simple question for all Java gurus.
I have a program looks like this:
........
public class TestThread extends Thread
{ ........
........
public static void main(String[] args)
{
TestThread t1 = new Thread();
TestThread t2 = new Thread();
t1.start();
t2.start();
}
public void run()
{
while(true)
{
// do something
}
}
}
=====================================
My question is: Does the main thread get terminated right after spawning
two threads?
Thanks,
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
Forum Rules
|
Top DevX Stories
Easy Web Services with SQL Server 2005 HTTP Endpoints
JavaOne 2005: Java Platform Roadmap Focuses on Ease of Development, Sun Focuses on the "Free" in F.O.S.S.
Wed Yourself to UML with the Power of Associations
Microsoft to Add AJAX Capabilities to ASP.NET
IBM's Cloudscape Versus MySQL
|
Bookmarks