aboutsummaryrefslogtreecommitdiff
path: root/include/BH/Ini.h
blob: cd544ea21d13aae4af3e12eb282387695de3009b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
#ifndef BH_INI_H
#define BH_INI_H

#include "IO.h"


typedef struct BH_Ini BH_Ini;

BH_Ini *BH_IniNew(void);


void BH_IniFree(BH_Ini *ini);


int BH_IniLoad(BH_Ini *ini,
               BH_IO *io);


int BH_IniSave(BH_Ini *ini,
               BH_IO *io);


int BH_IniSetString(BH_Ini *ini,
                    const char *section,
                    const char *key,
                    const char *value);


const char *BH_IniString(BH_Ini *ini,
                         const char *section,
                         const char *key);


void BH_IniRemoveSection(BH_Ini *ini,
                         const char *section);


void BH_IniRemoveKey(BH_Ini *ini,
                     const char *section,
                     const char *key);


void *BH_IniSectionIterNext(BH_Ini *ini,
                            void *iter);


void *BH_IniSectionIterAt(BH_Ini *ini,
                          const char *section);


const char *BH_IniSectionIterName(void *iter);


void BH_IniSectionIterRemove(BH_Ini *ini,
                             void *iter);


void *BH_IniKVIterNext(void *section,
                       void *iter);


void *BH_IniKVIterAt(void *section,
                     const char *key);


const char *BH_IniKVIterKey(void *iter);


const char *BH_IniKVIterValue(void *iter);


void BH_IniKVIterRemove(void *section,
                        void *iter);


#endif /* BH_INI_H */