CAFE
Computational Analysis of gene Family Evolution
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
memalloc.h
Go to the documentation of this file.
1 #ifndef __MEMALLOC_H__
2 #define __MEMALLOC_H__
3 
4 #include<string.h>
5 #include<errno.h>
6 #include<stdarg.h>
7 #include<stdlib.h>
8 #include<stdio.h>
9 
10 
11 typedef void (*func_memory_free)(void* data);
12 
13 extern void* memory_new(size_t count, size_t size );
14 extern void* memory_new_with_init(int count, int size, void* init);
15 extern void* memory_realloc_with_data(void** data, int old, int newsize, int size, func_memory_free func, int elementsize );
16 extern void* memory_realloc(void* data, int count, int size );
17 extern void memory_free(void* data);
18 extern void** memory_new_2dim(int row, int col, int size );
19 extern void memory_free_2dim(void** data, int row, int col, func_memory_free func );
20 extern void** memory_copy_2dim(void** dst, void** src, int row, int col, int size );
21 
22 #endif
void memory_free(void *data)
Definition: memalloc.c:83
void * memory_new_with_init(int count, int size, void *init)
Definition: memalloc.c:44
void * memory_realloc_with_data(void **data, int old, int newsize, int size, func_memory_free func, int elementsize)
Definition: memalloc.c:51
void(* func_memory_free)(void *data)
Definition: memalloc.h:11
void * memory_new(size_t count, size_t size)
Definition: memalloc.c:4
void * memory_realloc(void *data, int count, int size)
Definition: memalloc.c:73
void ** memory_new_2dim(int row, int col, int size)
Definition: memalloc.c:15
void memory_free_2dim(void **data, int row, int col, func_memory_free func)
Definition: memalloc.c:89
void ** memory_copy_2dim(void **dst, void **src, int row, int col, int size)
Definition: memalloc.c:112