Some other thread interrupts thread T . The specified amount of real time has elapsed, more or less. If timeout is zero, however, then real time is not taken into consideration and the thread simply waits until notified. The thread T is then removed from the wait set for this object and re-enabled for thread scheduling. Thread T then returns from the invocation of the wait method.
T is exactly as it was when the wait method was invoked.
If the current thread is interrupted by another thread while it is waiting, then an InterruptedException is thrown. This exception is not thrown until the lock status of this object has been restored as described above. This method should only be called by a thread that is the owner of this object's monitor. See the notify method for a description of the ways in which a thread can become the owner of a monitor. IllegalMonitorStateException - if the current thread is not the owner of the object's monitor.