PIPS-NLP
Classes | Macros | Typedefs | Functions | Variables
hash.C File Reference
#include <cstring>
#include <cstdio>
#include <cstdlib>
#include <iostream>
#include <fstream>

Classes

struct  node
 
struct  HashTable
 

Macros

#define NUMPRIMES   18
 

Typedefs

typedef struct nodeListPtr
 
typedef struct node List
 

Functions

void OutOfSpace ()
 
char * StrDup (char *s1, const char *message)
 
HashTableNewHashTable (int size)
 
int hash (HashTable *table, char *string)
 
int GetIndex (HashTable *table, char *name)
 
int Insert (HashTable *table, char *name, int index)
 
int PrintHashTable (HashTable *table)
 
int DeleteHashTable (HashTable *table)
 
int PrintHashTableStats (HashTable *table)
 

Variables

static int prime [NUMPRIMES]
 

Macro Definition Documentation

#define NUMPRIMES   18

Typedef Documentation

typedef struct node List
typedef struct node* ListPtr

Function Documentation

int DeleteHashTable ( HashTable table)
int GetIndex ( HashTable table,
char *  name 
)
int hash ( HashTable table,
char *  string 
)
int Insert ( HashTable table,
char *  name,
int  index 
)
HashTable* NewHashTable ( int  size)
void OutOfSpace ( )
int PrintHashTable ( HashTable table)
int PrintHashTableStats ( HashTable table)
char* StrDup ( char *  s1,
const char *  message 
)

Variable Documentation

int prime[NUMPRIMES]
static
Initial value:
= {29, 229, 883, 1669, 2791, 4801, 8629,
15289, 32749, 65521, 131071, 262139,
524287, 1048573, 2097143, 4194301,
8388593, 16777213}