]> mj.ucw.cz Git - libucw.git/blob - lib/simple-lists.h
Merge with git+ssh://cvs.ucw.cz/projects/sherlock/GIT/sherlock.git
[libucw.git] / lib / simple-lists.h
1 /*
2  *      UCW Library -- Linked Lists of Simple Items
3  *
4  *      (c) 2006 Martin Mares <mj@ucw.cz>
5  *
6  *      This software may be freely distributed and used according to the terms
7  *      of the GNU Lesser General Public License.
8  */
9
10 #ifndef _UCW_SIMPLE_LISTS_H
11 #define _UCW_SIMPLE_LISTS_H
12
13 #include "lib/clists.h"
14
15 typedef struct simp_node {
16   cnode n;
17   union {
18     byte *s;
19     void *p;
20     int i;
21     uns u;
22   };
23 } simp_node;
24
25 typedef struct simp2_node {
26   cnode n;
27   union {
28     byte *s1;
29     void *p1;
30     int i1;
31     uns u1;
32   };
33   union {
34     byte *s2;
35     void *p2;
36     int i2;
37     uns u2;
38   };
39 } simp2_node;
40
41 struct mempool;
42 simp_node *simp_append(struct mempool *mp, clist *l);
43 simp2_node *simp2_append(struct mempool *mp, clist *l);
44
45 /* Configuration sections */
46 extern struct cf_section cf_string_list_config;
47 extern struct cf_section cf_2string_list_config;
48
49 #endif