| 33:3a0064eb9421 | 34:828f3afd5c76 |
|---|---|
| 1 /* | |
| 2 * libtu/map.h | |
| 3 * | |
| 4 * Copyright (c) Tuomo Valkonen 1999-2000. | |
| 5 * See the included file LICENSE for details. | |
| 6 */ | |
| 7 | |
| 8 #ifndef LIBTU_MAP_H | |
| 9 #define LIBTU_MAP_H | |
| 10 | |
| 11 typedef struct _StringIntMap{ | |
| 12 const char *string; | |
| 13 int value; | |
| 14 } StringIntMap; | |
| 15 | |
| 16 #define END_STRINGINTMAP {NULL, 0} | |
| 17 | |
| 18 /* Return the index of str in map or -1 if not found. */ | |
| 19 extern int stringintmap_ndx(const StringIntMap *map, const char *str); | |
| 20 | |
| 21 #endif /* LIBTU_MAP_H */ |