blob: 9126706d98877b0e2688f2e3def81401b64a3c38 (
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
|
#ifndef INDEX_H
#define INDEX_H
#include "main.h"
#include "list.h"
typedef struct index_item_struct
{
int key;
void *data;
} index_item_t;
extern list_t *newIndex();
extern void addToIndex(list_t * list, int key, void *data);
extern void *getFromIndex(list_t * list, int key);
extern void delFromIndex(list_t * list, int key);
extern void delFromIndexWithObject(list_t * list, int key, void *f);
extern void actionIndexWithObject(list_t * list, void *f);
extern void destroyIndex(list_t * list);
extern void destroyIndexWithObject(list_t * list, void *f);
#endif
|