What is the use join() in Threads ?

Answers were Sorted based on User's Feedback



What is the use join() in Threads ?..

Answer / harish

It waits for the Parent Thread process to be completed.
Even though, Child process is completed. It waits for the
Parent Thread.

Is This Answer Correct ?    8 Yes 3 No

What is the use join() in Threads ?..

Answer / madan

if we want to finish main thread last i.e to ensure all
child threads terminate prior to the main thread

Is This Answer Correct ?    6 Yes 1 No

What is the use join() in Threads ?..

Answer / a.sreekanth

The join() method of a Thread instance can be used to "join" the start of a thread's execution to the end of another thread's execution so that a thread will not start running until another thread has ended. If join() is called on a Thread instance, the currently running thread will block until the Thread instance has finished executing.

Is This Answer Correct ?    0 Yes 0 No

What is the use join() in Threads ?..

Answer / venkat

Acoording to join the two Threads for some iterations.

Is This Answer Correct ?    0 Yes 9 No

What is the use join() in Threads ?..

Answer / padmaja

waits for specified number of milliseconds for thread to die

Is This Answer Correct ?    0 Yes 10 No

Post New Answer

More Core Java Interview Questions

What is the range of the char type?

3 Answers  


Can you call a method in a method?

0 Answers  


What are concepts of OOPS and how are they implemented in Java?

2 Answers   KPIT,


explain local datetime api in java8?

0 Answers  


What do you understand by final value?

0 Answers  






What does 3 dots mean in java?

0 Answers  


why would you use a synchronized block vs. Synchronized method? : Java thread

0 Answers  


What do you understand by garbage collection in Java? Can it be forced to run?

0 Answers   TCS,


write SQL command for table employee where print first name or last name start like "A" and who is working in domain(angular js,java,dotnet)

1 Answers  


what is meant by abstract class?

0 Answers   Aspire,


What is the purpose of the enableevents() method?

0 Answers  


Is it possible to write static method in abstract class? justyfy your answer?

5 Answers   Hexaware,


Categories