|
The support of Java threading also lies partially in java.lang.Object. This class has following three thread –related methods. Therefore, every thread object also has them (as it inherits them from java.lang.Object)
public final void wait()
public final void notify()
public final void notifyAll()
These three methods are extremely useful for threads to coordinate their actions when they are accessing common set of data or code. We will see the details of these method in synchronization section.