1/* exif-mnote-data-priv.h
2 *
3 * Copyright (c) 2003 Lutz Mueller <lutz@users.sourceforge.net>
4 *
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version.
9 *
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13 * Lesser General Public License for more details.
14 *
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the
17 * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18 * Boston, MA  02110-1301  USA.
19 */
20
21#ifndef __EXIF_MNOTE_DATA_PRIV_H__
22#define __EXIF_MNOTE_DATA_PRIV_H__
23
24#ifdef __cplusplus
25extern "C" {
26#endif /* __cplusplus */
27
28#include <libexif/exif-mnote-data.h>
29#include <libexif/exif-byte-order.h>
30#include <libexif/exif-log.h>
31
32typedef struct _ExifMnoteDataMethods ExifMnoteDataMethods;
33struct _ExifMnoteDataMethods {
34
35	/* Live cycle */
36	void (* free) (ExifMnoteData *);
37
38	/* Modification */
39	void (* save) (ExifMnoteData *, unsigned char **, unsigned int *);
40	void (* load) (ExifMnoteData *, const unsigned char *, unsigned int);
41	void (* set_offset)     (ExifMnoteData *, unsigned int);
42	void (* set_byte_order) (ExifMnoteData *, ExifByteOrder);
43
44	/* Query */
45	unsigned int (* count)           (ExifMnoteData *);
46        unsigned int (* get_id)          (ExifMnoteData *, unsigned int);
47	const char * (* get_name)        (ExifMnoteData *, unsigned int);
48	const char * (* get_title)       (ExifMnoteData *, unsigned int);
49	const char * (* get_description) (ExifMnoteData *, unsigned int);
50	char * (* get_value)             (ExifMnoteData *, unsigned int, char *val, unsigned int maxlen);
51};
52
53typedef struct _ExifMnoteDataPriv ExifMnoteDataPriv;
54
55struct _ExifMnoteData
56{
57	ExifMnoteDataPriv *priv;
58
59	ExifMnoteDataMethods methods;
60
61	/* Logging */
62	ExifLog *log;
63
64	/* Memory management */
65	ExifMem *mem;
66};
67
68void exif_mnote_data_construct      (ExifMnoteData *, ExifMem *mem);
69void exif_mnote_data_set_byte_order (ExifMnoteData *, ExifByteOrder);
70void exif_mnote_data_set_offset     (ExifMnoteData *, unsigned int);
71
72#ifdef __cplusplus
73}
74#endif /* __cplusplus */
75
76#endif /* __EXIF_MNOTE_PRIV_H__ */
77