Causes the current thread to wait until it is awakened, typically by being notified or interrupted.
In all respects, this method behaves as if wait(0L, 0)
had been called. See the specification of the wait(long, int)
method
for details.
IllegalMonitorStateException | if the current thread is not the owner of the object's monitor | |
InterruptedException | if any thread interrupted the current thread before or while the current thread was waiting. The interrupted status of the current thread is cleared when this exception is thrown. |
notify(), notifyAll(), wait(long), wait(long, int)
Diagram: Object