- enum ThreadState
- {
- INITIALIZING, // Thread is initializing itself
- SEARCHING, // Thread is performing work
- AVAILABLE, // Thread is waiting for work
- BOOKED, // Other thread (master) has booked us as a slave
- WORKISWAITING, // Master has ordered us to start
- TERMINATED // We are quitting and thread is terminated
- };
+ Thread(const Thread&); // Only declared to disable the default ones
+ Thread& operator=(const Thread&); // that are not suitable in this case.
+
+ typedef void (Thread::* Fn) ();
+
+public:
+ Thread(Fn fn);
+ ~Thread();