Tizen Native API
4.0
|
Functions | |
Eina_Lalloc * | eina_lalloc_new (void *data, Eina_Lalloc_Alloc alloc_cb, Eina_Lalloc_Free free_cb, int num_init) |
Creates a new lazy allocator. | |
void | eina_lalloc_free (Eina_Lalloc *a) |
Frees the resources for a lazy allocator. | |
Eina_Bool | eina_lalloc_elements_add (Eina_Lalloc *a, int num) |
Adds several elements to a lazy allocator. | |
Eina_Bool | eina_lalloc_element_add (Eina_Lalloc *a) |
Allocates one more of whatever the lazy allocator is allocating. | |
Typedefs | |
typedef Eina_Bool(* | Eina_Lalloc_Alloc )(void *user_data, int num) |
typedef void(* | Eina_Lalloc_Free )(void *user_data) |
typedef struct _Eina_Lalloc | Eina_Lalloc |
Defines | |
#define | EINA_LALLOC_ALLOC(function) ((Eina_Lalloc_Alloc)function) |
#define | EINA_LALLOC_FREE(function) ((Eina_Lalloc_Free)function) |
#define EINA_LALLOC_ALLOC | ( | function | ) | ((Eina_Lalloc_Alloc)function) |
function | The function to allocate. |
#define EINA_LALLOC_FREE | ( | function | ) | ((Eina_Lalloc_Free)function) |
function | The function to free. |
Public type definition for a lazy allocator.
Type definition for the callback used to allocate new items in a lazy allocator.
Type definition for the callback used to allocate new items in a lazy allocator.
Allocates one more of whatever the lazy allocator is allocating.
a | The lazy allocator to add an item to. |
Eina_Bool eina_lalloc_elements_add | ( | Eina_Lalloc * | a, |
int | num | ||
) |
Adds several elements to a lazy allocator.
a | The lazy allocater to add items to. |
num | The number of elements to add. |
void eina_lalloc_free | ( | Eina_Lalloc * | a | ) |
Frees the resources for a lazy allocator.
a | The lazy allocator to free. |
Eina_Lalloc* eina_lalloc_new | ( | void * | data, |
Eina_Lalloc_Alloc | alloc_cb, | ||
Eina_Lalloc_Free | free_cb, | ||
int | num_init | ||
) |
Creates a new lazy allocator.
data | The data for which memory will be allocated. |
alloc_cb | The callback to allocate memory for data items. |
free_cb | The callback to free memory for data items. |
num_init | The number of data items to initially allocate space for. |