Mercurial > hg > Members > kono > Cerium
view include/TaskManager/TaskQueueInfo.h @ 70:178459e03f5c
*** empty log message ***
author | gongo |
---|---|
date | Mon, 18 Feb 2008 01:13:00 +0900 |
parents | 90523ccc4dff |
children | 5c194c71eca8 |
line wrap: on
line source
#ifndef INCLUDED_TASK_QUEUE_INFO #define INCLUDED_TASK_QUEUE_INFO #ifndef INCLUDED_TASK # include "task.h" #endif #ifndef INCLUDED_HTASK_INFO # include "HTaskInfo.h" #endif typedef struct task_queue { HTaskPtr task; TaskQueuePtr next; } TaskQueue, *TaskQueuePtr; class TaskQueueInfo { public: /* constructor */ TaskQueueInfo(void); ~TaskQueueInfo(void); /* functions */ int init(int num); TaskQueuePtr create(HTaskPtr task); void free(TaskQueuePtr queue); static TaskQueuePtr append(TaskQueuePtr list, TaskQueuePtr q); private: /* variables */ TaskQueuePtr taskQueuePool; TaskQueuePtr freeTaskQueue; /* functions */ int extend_pool(int num); void destroy(void); }; #endif