1 /* This file is part of the Zebra server.
2 Copyright (C) 1994-2009 Index Data
4 Zebra is free software; you can redistribute it and/or modify it under
5 the terms of the GNU General Public License as published by the Free
6 Software Foundation; either version 2, or (at your option) any later
9 Zebra is distributed in the hope that it will be useful, but WITHOUT ANY
10 WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 You should have received a copy of the GNU General Public License
15 along with this program; if not, write to the Free Software
16 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
23 #include <idzebra/util.h>
27 typedef struct res_struct *Res;
30 Res res_open(Res res_def, Res over_res);
33 void res_close(Res r);
36 ZEBRA_RES res_read_file(Res r, const char *fname);
39 ZEBRA_RES res_write_file(Res r, const char *fname);
42 void res_clear(Res r);
45 const char *res_get(Res r, const char *name);
48 const char *res_get_def(Res r, const char *name, const char *def);
51 int res_get_match(Res r, const char *name, const char *value, const char *s);
54 void res_set(Res r, const char *name, const char *value);
57 int res_trav(Res r, const char *prefix, void *p,
58 void (*f)(void *p, const char *name, const char *value));
61 const char *res_get_prefix(Res r, const char *name, const char *prefix,
65 ZEBRA_RES res_get_int(Res r, const char *name, int *val);
69 void res_add(Res r, const char *name, const char *value);
72 void res_dump(Res r, int level);
75 int res_check(Res r_i, Res r_v);
83 * c-file-style: "Stroustrup"
84 * indent-tabs-mode: nil
86 * vim: shiftwidth=4 tabstop=8 expandtab