8 #ifndef __INIREADER_H__ 9 #define __INIREADER_H__ 11 #include "exiv2lib_export.h" 38 const char* name,
const char* value);
41 typedef char* (*ini_reader)(
char* str,
int num,
void* stream);
90 #ifndef INI_ALLOW_MULTILINE 91 #define INI_ALLOW_MULTILINE 1 98 #define INI_ALLOW_BOM 1 105 #ifndef INI_ALLOW_INLINE_COMMENTS 106 #define INI_ALLOW_INLINE_COMMENTS 1 108 #ifndef INI_INLINE_COMMENT_PREFIXES 109 #define INI_INLINE_COMMENT_PREFIXES ";" 113 #ifndef INI_USE_STACK 114 #define INI_USE_STACK 1 118 #ifndef INI_STOP_ON_FIRST_ERROR 119 #define INI_STOP_ON_FIRST_ERROR 0 124 #define INI_MAX_LINE 200 198 std::map<std::string, std::string> _values;
200 static int ValueHandler(
void* user,
const char* section,
const char* name,
205 #endif // __INIREADER_H__ int ini_parse(const char *filename, ini_handler handler, void *user)
Parse given INI-style file. May have [section]s, name=value pairs (whitespace stripped), and comments starting with ';' (semicolon). Section is "" if name=value pair parsed before any section heading. name:value pairs are also supported as a concession to Python's configparser.
Definition: ini.cpp:198
char *(* ini_reader)(char *str, int num, void *stream)
Typedef for prototype of fgets-style reader function.
Definition: ini.hpp:41
int ini_parse_file(FILE *file, ini_handler handler, void *user)
Same as ini_parse(), but takes a FILE* instead of filename. This doesn't close the file when it's fin...
Definition: ini.cpp:192
int(* ini_handler)(void *user, const char *section, const char *name, const char *value)
typedef for prototype of handler function.
Definition: ini.hpp:37
int ini_parse_stream(ini_reader reader, void *stream, ini_handler handler, void *user)
Same as ini_parse(), but takes an ini_reader function pointer instead of filename. Used for implementing custom or string-based I/O.
Definition: ini.cpp:88
IPTC string type.
Definition: types.hpp:147
Read an INI file into easy-to-access name/value pairs. (Note that I've gone for simplicity here rathe...
Definition: ini.hpp:137
Provides classes and functions to encode and decode Exif and Iptc data. The libexiv2 API consists of ...
Definition: asfvideo.hpp:36