Object’s wait method causes the Thread the Object is running in to stop executing, possibly forever.
It won’t continue executing until notify() has been called, or unless wait() was called with a timeout parameter in which case it will continue after the timeout period.
The notifyAll() method can be used to notify all Threads waiting on the Object Thread’s monitor.