The methods wait , notify , and notifyAll defined in java.lang.Object , used to coordinate activities across threads. This section presents examples of these constructs, along with boxed summaries of notation and conventions. It concludes with a reference summary of principal Java concurrency constructs and their properties. A client is just any Java object that sends a request to another Java object, and a server is just any object receiving such a request. Most objects play the roles of both clients and servers.
Threads provide another option.
The Java Thread framework allows an activity to be initiated in a new thread, causing it to proceed asynchronously. Nearly any kind of activity can be performed in a Java Thread . Here is a class describing objects that print a message to a java.awt.TextArea when their run method is invoked. The methods part of a box is omitted when there is no reason to list any of the methods. Even when present, qualifiers, arguments, return types, constructors, inherited methods, and unreferenced methods are often omitted to reduce clutter.