| ||||
Copyright 1999 Sams Publishing |
|
Using interrupt() |
The interrupt() method of ThreadGroup can be used to signal an interrupt to all the threads in the group and subgroups. This method can be useful if several threads have been spawned to handle a task, and its time to signal all of them to shut down. (See Chapter 5, Gracefully Stopping Threads, for more on signaling threads to die by interrupting them.) |
| |||
Toc |