diff options
Diffstat (limited to 'src/threadpool.h')
| -rw-r--r-- | src/threadpool.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/threadpool.h b/src/threadpool.h index db6fa2e..d7b713c 100644 --- a/src/threadpool.h +++ b/src/threadpool.h | |||
| @@ -9,12 +9,18 @@ typedef struct cq cqueue; | |||
| 9 | typedef struct tp threadpool; | 9 | typedef struct tp threadpool; |
| 10 | 10 | ||
| 11 | task * task_init(task_callback cb, void *arg); | 11 | task * task_init(task_callback cb, void *arg); |
| 12 | void task_free(task *ts); | 12 | void task_free(void *ts); |
| 13 | int task_fire(task *ts); | 13 | int task_fire(task *ts); |
| 14 | 14 | ||
| 15 | cqueue * cqueue_init(); | 15 | cqueue * cqueue_init(); |
| 16 | void cqueue_cancel(cqueue * const cq); | 16 | void cqueue_cancel(cqueue * const cq); |
| 17 | void cqueue_free(void *cq); | 17 | void cqueue_free(void *cq); |
| 18 | 18 | int cqueue_addtask(cqueue * const cq, task * const tsk); | |
| 19 | task * cqueue_waitpop(cqueue * const cq); | ||
| 20 | int cqueue_registerthreads(cqueue * const cq, int threads); | ||
| 21 | int cqueue_registerthread(cqueue * const cq); | ||
| 22 | int cqueue_iscanceled(cqueue * const cq); | ||
| 23 | int cqueue_numthreads(cqueue * const cq); | ||
| 24 | int cqueue_numtasks(cqueue * const cq); | ||
| 19 | 25 | ||
| 20 | #endif \ No newline at end of file | 26 | #endif \ No newline at end of file |
