00001 /* ---------------------------------------------------------------------------- 00002 * $Id: smd_queue.h,v 1.1 2003/01/27 18:28:38 jlewalle Exp $ 00003 * 00004 * --------------------------------------------------------------------------*/ 00005 #if !defined(_INCLUDED_SMD_QUEUE_H_HEADER__) 00006 #define _INCLUDED_SMD_QUEUE_H_HEADER__ 00007 00018 typedef struct smd_threadpool_t smd_threadpool_t; 00019 00026 typedef sul_error_t *(*smd_threadpool_fn_t)(void *baton, apr_pool_t *pool); 00027 00039 sul_error_t *smd_threadpool_create(smd_threadpool_t **threadp, apr_size_t quesz, 00040 apr_size_t numthrds, smd_threadpool_fn_t fn, 00041 apr_pool_t *pool); 00042 00050 sul_error_t *smd_threadpool_spawn(smd_threadpool_t *threadp, apr_pool_t *pool); 00051 00061 sul_error_t *smd_threadpool_push(smd_threadpool_t *threadp, void *arg); 00062 00070 sul_boolean_t smd_threadpool_running(smd_threadpool_t *threadp); 00071 00078 sul_error_t *smd_threadpool_destroy(smd_threadpool_t *threadp); 00079 00082 #endif