85
Java Thread resume() method
The resume() method of thread class is only used with suspend() method. This method is used to resume a thread which was suspended using suspend() method. This method allows the suspended thread to start again.
Syntax
Return value
This method does not return any value.
Exception
SecurityException: If the current thread cannot modify the thread.
Example
Output:
Thread-0 1 Thread-2 1 Thread-1 1 Thread-0 2 Thread-2 2 Thread-1 2 Thread-0 3 Thread-2 3 Thread-1 3 Thread-0 4 Thread-2 4 Thread-1 4
Next TopicJava Thread