mirror of
https://gitee.com/acl-dev/acl.git
synced 2024-12-16 01:40:52 +08:00
cc05b877a2
first commit acl to github
27 lines
756 B
C
27 lines
756 B
C
#ifndef __ACL_DBUF_POOL_INCLUDE_H__
|
|
#define __ACL_DBUF_POOL_INCLUDE_H__
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
typedef struct ACL_DBUF_POOL ACL_DBUF_POOL;
|
|
|
|
/* public */
|
|
ACL_API ACL_DBUF_POOL *acl_dbuf_pool_create(int block_size);
|
|
ACL_API void acl_dbuf_pool_destroy(ACL_DBUF_POOL *pool);
|
|
ACL_API void acl_dbuf_pool_free(ACL_DBUF_POOL *pool, void *ptr, int length);
|
|
ACL_API void *acl_dbuf_pool_alloc(ACL_DBUF_POOL *pool, int length);
|
|
ACL_API void *acl_dbuf_pool_calloc(ACL_DBUF_POOL *pool, int length);
|
|
ACL_API void *acl_dbuf_pool_memdup(ACL_DBUF_POOL *pool, const void *s, size_t len);
|
|
ACL_API char *acl_dbuf_pool_strdup(ACL_DBUF_POOL *pool, const char *s);
|
|
|
|
/* private */
|
|
ACL_API void acl_dbuf_pool_test(size_t max);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif
|