Mercurial > hg > Members > kono > Cerium
annotate include/TaskManager/TaskManager.h @ 217:897aeb144569
fix
author | gongo@localhost.localdomain |
---|---|
date | Wed, 04 Feb 2009 22:50:42 +0900 |
parents | 894675539cbf |
children | 29e338dbc280 |
rev | line source |
---|---|
3 | 1 #ifndef INCLUDED_TASK_MANAGER |
2 #define INCLUDED_TASK_MANAGER | |
3 | |
4 #ifndef INCLUDED_TASK_MANAGER_IMPL | |
5 # include "TaskManagerImpl.h" | |
6 #endif | |
7 | |
8 class TaskManager { | |
9 public: | |
10 /* constructor */ | |
11 TaskManager(int num = 1); // The number of threads | |
194 | 12 ~TaskManager(void); |
3 | 13 |
14 /* variables */ | |
216
894675539cbf
rename cerium_main to TMmain, add TMend()
gongo@localhost.localdomain
parents:
194
diff
changeset
|
15 |
894675539cbf
rename cerium_main to TMmain, add TMend()
gongo@localhost.localdomain
parents:
194
diff
changeset
|
16 TaskManagerImpl *m_impl; |
894675539cbf
rename cerium_main to TMmain, add TMend()
gongo@localhost.localdomain
parents:
194
diff
changeset
|
17 void (*tm_end)(void); |
894675539cbf
rename cerium_main to TMmain, add TMend()
gongo@localhost.localdomain
parents:
194
diff
changeset
|
18 |
894675539cbf
rename cerium_main to TMmain, add TMend()
gongo@localhost.localdomain
parents:
194
diff
changeset
|
19 /* user function */ |
894675539cbf
rename cerium_main to TMmain, add TMend()
gongo@localhost.localdomain
parents:
194
diff
changeset
|
20 HTaskPtr create_task(int cmd); |
894675539cbf
rename cerium_main to TMmain, add TMend()
gongo@localhost.localdomain
parents:
194
diff
changeset
|
21 void run(void); |
894675539cbf
rename cerium_main to TMmain, add TMend()
gongo@localhost.localdomain
parents:
194
diff
changeset
|
22 void *allocate(int size); |
894675539cbf
rename cerium_main to TMmain, add TMend()
gongo@localhost.localdomain
parents:
194
diff
changeset
|
23 void set_TMend(void (*endf)(void)); |
3 | 24 |
25 /* functions */ | |
26 void init(void); | |
20 | 27 void finish(void); |
14 | 28 |
3 | 29 private: |
30 int machineNum; | |
31 }; | |
32 | |
33 #endif | |
109 | 34 |
35 extern TaskManager *manager; |