1 /* $Id: list.h 6168 2003-01-21 06:27:32Z alexk $
8 #include <inn/defines.h>
18 struct node *tailpred;
23 /* initialise a new list */
24 void list_new(struct list *list);
26 /* add a node to the head of the list */
27 struct node *list_addhead(struct list *list, struct node *node);
29 /* add a node to the tail of the list */
30 struct node *list_addtail(struct list *list, struct node *node);
32 /* return a pointer to the first node on the list */
33 struct node *list_head(struct list *list);
35 /* return a pointer to the last node on the list */
36 struct node *list_tail(struct list *list);
38 struct node *list_succ(struct node *node);
39 struct node *list_pred(struct node *node);
41 struct node *list_remhead(struct list *list);
42 struct node *list_remove(struct node *node);
43 struct node *list_remtail(struct list *list);
44 struct node *list_insert(struct list *list, struct node *node,
47 bool list_isempty(struct list *list);
51 #endif /* INN_LIST_H */