EXIF library (libexif) API 0.6.24
exif-mem.h
Go to the documentation of this file.
1
5/* exif-mem.h
6 *
7 * Copyright (c) 2003 Lutz Mueller <lutz@users.sourceforge.net>
8 *
9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Lesser General Public
11 * License as published by the Free Software Foundation; either
12 * version 2 of the License, or (at your option) any later version.
13 *
14 * This library is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 * Lesser General Public License for more details.
18 *
19 * You should have received a copy of the GNU Lesser General Public
20 * License along with this library; if not, write to the
21 * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
22 * Boston, MA 02110-1301 USA.
23 */
24
25#ifndef LIBEXIF_EXIF_MEM_H
26#define LIBEXIF_EXIF_MEM_H
27
28#include <libexif/exif-utils.h>
29
30#ifdef __cplusplus
31extern "C" {
32#endif /* __cplusplus */
33
39typedef void * (* ExifMemAllocFunc) (ExifLong s);
40
47typedef void * (* ExifMemReallocFunc) (void *p, ExifLong s);
48
54typedef void (* ExifMemFreeFunc) (void *p);
55
57typedef struct _ExifMem ExifMem;
58
70void exif_mem_ref (ExifMem *);
71
75void exif_mem_unref (ExifMem *);
76
77void *exif_mem_alloc (ExifMem *m, ExifLong s);
78void *exif_mem_realloc (ExifMem *m, void *p, ExifLong s);
79void exif_mem_free (ExifMem *m, void *p);
80
86
87#ifdef __cplusplus
88}
89#endif /* __cplusplus */
90
91#endif /* !defined(LIBEXIF_EXIF_MEM_H) */
void(* ExifMemFreeFunc)(void *p)
Free method for ExifMem.
Definition exif-mem.h:54
void *(* ExifMemAllocFunc)(ExifLong s)
Should work like calloc()
Definition exif-mem.h:39
struct _ExifMem ExifMem
ExifMem define a memory allocator.
Definition exif-mem.h:57
ExifMem * exif_mem_new_default(void)
Create a new ExifMem with default values for your convenience.
Definition exif-mem.c:95
void exif_mem_ref(ExifMem *)
Refcount an ExifMem.
Definition exif-mem.c:54
ExifMem * exif_mem_new(ExifMemAllocFunc a, ExifMemReallocFunc r, ExifMemFreeFunc f)
Create a new ExifMem.
Definition exif-mem.c:34
void exif_mem_unref(ExifMem *)
Unrefcount an ExifMem.
Definition exif-mem.c:61
void *(* ExifMemReallocFunc)(void *p, ExifLong s)
Should work like realloc()
Definition exif-mem.h:47
EXIF data manipulation functions and types.
uint32_t ExifLong
EXIF Unsigned Long data type.
Definition exif-utils.h:54