|
HOME
SIP/media Features
High Performance SIP
Small Footprint SIP
Symbian Port
FAQ
Documentation
Licensing
Download
Development (Trac)
Projects using pjsip
Mailing List
Open Source Links
About: PJLIB, PJLIB-UTIL, PJSIP, and PJMEDIA are created by: Benny Prijono <bennylp pjsip.org>
|
|
Home --> Documentations --> PJLIB Reference
Detailed Description
This structure contains the declaration for pool factory interface.
Forward declaration for memory pool factory.
Field Documentation
Create a new pool from the pool factory.
- Parameters:
-
| factory | The pool factory. |
| name | the name to be assigned to the pool. The name should not be longer than PJ_MAX_OBJ_NAME (32 chars), or otherwise it will be truncated. |
| initial_size | the size of initial memory blocks taken by the pool. Note that the pool will take 68+20 bytes for administrative area from this block. |
| increment_size | the size of each additional blocks to be allocated when the pool is running out of memory. If user requests memory which is larger than this size, then an error occurs. Note that each time a pool allocates additional block, it needs 20 bytes (equal to sizeof(pj_pool_block)) to store some administrative info. |
| callback | Cllback to be called when error occurs in the pool. Note that when an error occurs during pool creation, the callback itself is not called. Instead, NULL will be returned. |
- Returns:
- the memory pool, or NULL.
Dump pool status to log.
- Parameters:
-
| factory | The pool factory. |
This is optional callback to be called by allocation policy when it allocates a new memory block. The factory may use this callback for example to keep track of the total number of memory blocks currently allocated by applications.
- Parameters:
-
| factory | The pool factory. |
| size | Size requested by application. |
- Returns:
- MUST return PJ_TRUE, otherwise the block allocation is cancelled.
This is optional callback to be called by allocation policy when it frees memory block. The factory may use this callback for example to keep track of the total number of memory blocks currently allocated by applications.
- Parameters:
-
| factory | The pool factory. |
| size | Size freed. |
Release the pool to the pool factory.
- Parameters:
-
| factory | The pool factory. |
| pool | The pool to be released. |
The documentation for this struct was generated from the following files:
PJLIB Open Source, high performance, small footprint, and very very portable framework
Copyright (C) 2006-2009 Teluu Inc.
|
|