1 #ifndef RHESUS_RHESUSTASK_H_
2 #define RHESUS_RHESUSTASK_H_
7 #include "SyncObject.h"
20 static RhesusTask& CreateNew(
const char* name, FUNCPTR
function, INT32 priority = Task::kDefaultPriority, UINT32 stackSize = 20000);
21 static void Finalize();
23 virtual ~RhesusTask();
25 bool Start(UINT32 arg0 = 0, UINT32 arg1 = 0, UINT32 arg2 = 0, UINT32 arg3 = 0, UINT32 arg4 = 0,
26 UINT32 arg5 = 0, UINT32 arg6 = 0, UINT32 arg7 = 0, UINT32 arg8 = 0);
42 bool SetPriority(INT32 priority);
43 const char* GetName();
47 static map<const char*, RhesusTask*> m_tasks;
49 static INT32 intern_taskEntry(UINT32 inst, UINT32 arg0, UINT32 arg1, UINT32 arg2, UINT32 arg3, UINT32 arg4,
50 UINT32 arg5, UINT32 arg6, UINT32 arg7, UINT32 arg8);
52 static void AddTask(RhesusTask* task);
53 static void RemoveTask(
const char* name);
55 RhesusTask(
const char* name, FUNCPTR
function, INT32 priority = Task::kDefaultPriority, UINT32 stackSize = 20000);
59 SyncObject m_taskEndMutex;