PIPS-NLP
hash.h
Go to the documentation of this file.
1 /* OOQP *
2  * Authors: E. Michael Gertz, Stephen J. Wright *
3  * (C) 2001 University of Chicago. See Copyright Notification in OOQP */
4 
5 /* hash table definitions
6  *
7  * PCx beta-2.0 10/31/96.
8  *
9  * Authors: Joe Czyzyk, Sanjay Mehrotra, Steve Wright.
10  *
11  * (C) 1996 University of Chicago. See COPYRIGHT in main directory.
12  */
13 
14 #ifndef HashFile
15 #define HashFile
16 
17 typedef struct qpnode *qpListPtr;
18 
19 typedef struct qpnode {
20  int index;
21  char *entry;
22  qpListPtr next;
23 } qpList;
24 
25 typedef struct {
26  qpListPtr *list;
27  int size;
28 } qpHashTable;
29 
30 #ifdef __cplusplus
31 extern "C" {
32 #endif
33  qpHashTable *NewHashTable(int size);
34  int Insert (qpHashTable * table, char * name, int index );
35  int GetIndex( qpHashTable * table, char name[] );
36  int DeleteHashTable(qpHashTable * table);
37 #ifdef __cplusplus
38 }
39 #endif
40 
41 #endif
int Insert(qpHashTable *table, char *name, int index)
struct qpnode * qpListPtr
Definition: hash.h:17
int GetIndex(qpHashTable *table, char name[])
Definition: hash.h:25
char * entry
Definition: hash.h:21
int size
Definition: hash.h:27
int DeleteHashTable(qpHashTable *table)
qpHashTable * NewHashTable(int size)
Definition: hash.C:68
qpListPtr * list
Definition: hash.h:26
int index
Definition: hash.h:20
Definition: hash.h:19
qpListPtr next
Definition: hash.h:22
struct qpnode qpList