Java Reference
In-Depth Information
Many classes implicitly create threads within an application. For ex-
cial thread for dealing with all associated events. Similarly, Remote
Method Invocation, also mentioned in
Chapter 25
,
creates threads for
responding to remote method invocations. Some of these threads may
be daemons and others may not, so use of these classes can keep your
application running longer than you may intend. In these circumstances
the use of the
exit
method becomes essential if there is no other way to
terminate the threads.