|If a Thread wants to pass its execution to give the remaining Thread the same priority, then. We should go for yield().
|If a Thread wants to wait until the completion of some other Thread, then we should go for join().
|If a Thread doesn’t want to perform any operation for a particular amount of time then we should go to sleep()
|Is it overloaded?
|Is it final?
|Is it throws an Interrupted Exception?
|Is it native?
|sleep(long ms) native
sleep(long ms, int ns) nonnative
|Is it static?
Similar Java Tutorials
- Odd Even in Java
- Method to print exception information in Java
- Exception Handling by Using try-catch in Java
- Checked Exception vs Unchecked Exception
- Exception Hierarchy in Java
- Java Exception Handling Interview Questions
- final finally finalize in java
- User Defined Exception in Java
- Exception Handling Keyword in Java
- throw throws in Java
- try with multiple catch block in Java
- Threads in Java
- Thread priority in Java