17#include "dictionary.h"
dictionary * iniparser_load(const char *ininame)
Parse an ini file and return an allocated dictionary object.
double iniparser_getdouble(const dictionary *d, const char *key, double notfound)
Get the string associated to a key, convert to a double.
void iniparser_unset(dictionary *ini, const char *entry)
Delete an entry in a dictionary.
void iniparser_set_error_callback(int(*errback)(const char *,...))
Configure a function to receive the error messages.
int iniparser_getsecnkeys(const dictionary *d, const char *s)
Get the number of keys in a section of a dictionary.
const char * iniparser_getsecname(const dictionary *d, int n)
Get name for section n in a dictionary.
void iniparser_dumpsection_ini(const dictionary *d, const char *s, FILE *f)
Save a dictionary section to a loadable ini file.
void iniparser_dump(const dictionary *d, FILE *f)
Dump a dictionary to an opened file pointer.
void iniparser_freedict(dictionary *d)
Free all memory associated to an ini dictionary.
int iniparser_getint(const dictionary *d, const char *key, int notfound)
Get the string associated to a key, convert to an int.
int64_t iniparser_getint64(const dictionary *d, const char *key, int64_t notfound)
Get the string associated to a key, convert to an int64_t.
uint64_t iniparser_getuint64(const dictionary *d, const char *key, uint64_t notfound)
Get the string associated to a key, convert to an uint64_t.
int iniparser_find_entry(const dictionary *ini, const char *entry)
Finds out if a given entry exists in a dictionary.
dictionary * iniparser_load_file(FILE *in, const char *ininame)
Parse an ini file and return an allocated dictionary object.
int iniparser_getnsec(const dictionary *d)
Get number of sections in a dictionary.
int iniparser_set(dictionary *ini, const char *entry, const char *val)
Set an entry in a dictionary.
long int iniparser_getlongint(const dictionary *d, const char *key, long int notfound)
Get the string associated to a key, convert to an long int.
const char ** iniparser_getseckeys(const dictionary *d, const char *s, const char **keys)
Get the number of keys in a section of a dictionary.
void iniparser_dump_ini(const dictionary *d, FILE *f)
Save a dictionary to a loadable ini file.
int iniparser_getboolean(const dictionary *d, const char *key, int notfound)
Get the string associated to a key, convert to a boolean.
const char * iniparser_getstring(const dictionary *d, const char *key, const char *def)
Get the string associated to a key.