… | |
… | |
7 | * |
7 | * |
8 | * Portions of this file were derived from sources bearing the following license: |
8 | * Portions of this file were derived from sources bearing the following license: |
9 | * Copyright © 2005 William Pitcock, et al. |
9 | * Copyright © 2005 William Pitcock, et al. |
10 | * Rights to this code are as documented in doc/pod/license.pod. |
10 | * Rights to this code are as documented in doc/pod/license.pod. |
11 | * |
11 | * |
12 | * $Id: confparse.h,v 1.6 2007/09/16 18:54:42 pippijn Exp $ |
12 | * $Id: confparse.h,v 1.7 2007/09/22 14:27:26 pippijn Exp $ |
13 | */ |
13 | */ |
14 | |
14 | |
15 | #ifndef CONFPARSE_H |
15 | #ifndef CONFPARSE_H |
16 | #define CONFPARSE_H |
16 | #define CONFPARSE_H |
17 | |
17 | |
18 | #include <common/util.h> |
18 | #include <util/containers.h> |
19 | #include <ermyth/callback.h> |
19 | #include <ermyth/callback.h> |
20 | #include <ermyth/type_traits.h> |
20 | #include <ermyth/type_traits.h> |
21 | |
21 | |
22 | struct config_file_t : zero_initialised |
22 | struct config_file_t : zero_initialised |
23 | { |
23 | { |
… | |
… | |
98 | { |
98 | { |
99 | } |
99 | } |
100 | }; |
100 | }; |
101 | |
101 | |
102 | E void init_newconf (void); |
102 | E void init_newconf (void); |
103 | E void deinit_conf (void); |
103 | E void conf_cleanup (void); |
104 | E struct ConfTable *find_top_conf (char const * const name); |
104 | E struct ConfTable *find_top_conf (char const * const name); |
105 | E struct ConfTable *find_conf_item (char const * const name, ConfTable::list_type &conflist); |
105 | E struct ConfTable *find_conf_item (char const * const name, ConfTable::list_type &conflist); |
106 | E void add_top_conf (char const * const name, int (*handler) (config_entry_t *ce)); |
106 | E void add_top_conf (char const * const name, int (*handler) (config_entry_t *ce)); |
107 | E void add_conf_item (char const * const name, ConfTable::list_type &conflist, int (*handler) (config_entry_t *ce)); |
107 | E void add_conf_item (char const * const name, ConfTable::list_type &conflist, int (*handler) (config_entry_t *ce)); |
108 | E void del_top_conf (char const * const name); |
108 | E void del_top_conf (char const * const name); |