[Logo]
Forums Register Login
What happens if we call join(), before start()?
What happens if we call newThread.join(), before newThread.start(), let's say, in main method (thread)? I didn't see any effects...
Nothing. The method just returns... which you have seen.

Henry
Following is the implementation of Thread.join(long millis). Calling newThread.join() leads to join(0) being called which in turn,as Henry said,causes the method to return,because isAlive() for a thread that has not been started would return false.


This thread has been viewed 2171 times.

All times above are in ranch (not your local) time.
The current ranch time is
Sep 23, 2018 19:46:12.