Main Page | Alphabetical List | Data Structures | File List | Data Fields | Globals | Related Pages

hash_table.h

00001 /*
00002 Copyright (C) 2003-2004 Douglas Thain and the University of Wisconsin
00003 Copyright (C) 2005- The University of Notre Dame
00004 This software is distributed under a BSD-style license.
00005 See the file COPYING for details.
00006 */
00007 
00008 #ifndef HASH_TABLE_H
00009 #define HASH_TABLE_H
00010 
00011 typedef unsigned (*hash_func_t) ( const char *key );
00012 
00013 struct hash_table * hash_table_create( int buckets, hash_func_t func );
00014 void                hash_table_delete( struct hash_table *h );
00015 
00016 int    hash_table_size  ( struct hash_table *h );
00017 int    hash_table_insert( struct hash_table *h, const char *key, const void *value );
00018 void * hash_table_lookup( struct hash_table *h, const char *key );
00019 void * hash_table_remove( struct hash_table *h, const char *key );
00020 
00021 void   hash_table_firstkey( struct hash_table *h );
00022 int    hash_table_nextkey( struct hash_table *h, char **key, void **value );
00023 
00024 unsigned hash_string( const char *s );
00025 
00026 #endif

Generated on Fri Oct 31 16:58:30 2008 for cctools by  doxygen 1.3.9.1