Changes needed to run on OS X... Example runs on my laptop now. No need to push...
[model-checker.git] / schedule.h
1 #ifndef __SCHEDULE_H__
2 #define __SCHEDULE_H__
3
4 #include <list>
5 #include "mymemory.h"
6
7 /* Forward declaration */
8 class Thread;
9
10 class Scheduler {
11 public:
12         Scheduler();
13         void add_thread(Thread *t);
14         void remove_thread(Thread *t);
15         Thread * next_thread(void);
16         Thread * get_current_thread(void);
17         void print();
18
19         SNAPSHOTALLOC
20 private:
21         std::list<Thread *> readyList;
22         Thread *current;
23 };
24
25 #endif /* __SCHEDULE_H__ */