Tom Kelliher, CS 245
Oct. 9, 2006
Deliverables due Wednesday.
Complete the lab.
Class design.
Threads II: Synchronization.
class Foo extends applet { Bar b = new Bar(); public void init() { ... b.start(); // Get the thread going. ... } } class Bar extends Thread { ... public void run() { // This is where the thread "lives." }Other thread methods:
sleep()
start()
stop()
-- deprecated.