OpenSWMM Engine  6.0.0-alpha.1
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.1)
Loading...
Searching...
No Matches
hash.h
Go to the documentation of this file.
1//-----------------------------------------------------------------------------
2// hash.h
3//
4// Header file for Hash Table module hash.c.
5//-----------------------------------------------------------------------------
6
7#ifndef HASH_H
8#define HASH_H
9
10
11#define HTMAXSIZE 1999
12#define NOTFOUND -1
13
14struct HTentry
15{
16 char *key;
17 int data;
18 struct HTentry *next;
19};
20
21typedef struct HTentry *HTtable;
22
23HTtable* HTcreate(void);
24int HTinsert(HTtable *, char *, int);
25int HTfind(HTtable *, const char *);
26char* HTfindKey(HTtable *, const char *);
27void HTfree(HTtable *);
28
29
30#endif //HASH_H
int HTfind(HTtable *, const char *)
Definition hash.c:73
char * HTfindKey(HTtable *, const char *)
Definition hash.c:87
struct HTentry * HTtable
Definition hash.h:21
HTtable * HTcreate(void)
Definition hash.c:51
int HTinsert(HTtable *, char *, int)
Definition hash.c:59
void HTfree(HTtable *)
Definition hash.c:101
Definition hash.h:15
char * key
Definition hash.h:16
int data
Definition hash.h:17
struct HTentry * next
Definition hash.h:18