/* Do not edit this file. It was automatically generated. */ #ifndef HEADER_Hashtable #define HEADER_Hashtable /* htop (C) 2004-2006 Hisham H. Muhammad Released under the GNU GPL, see the COPYING file in the source distribution for its full text. */ #include #include #include "debug.h" typedef struct Hashtable_ Hashtable; typedef void(*Hashtable_PairFunction)(int, void*, void*); typedef struct HashtableItem { int key; void* value; struct HashtableItem* next; } HashtableItem; struct Hashtable_ { int size; HashtableItem** buckets; int items; bool owner; }; HashtableItem* HashtableItem_new(int key, void* value); Hashtable* Hashtable_new(int size, bool owner); void Hashtable_delete(Hashtable* this); inline int Hashtable_size(Hashtable* this); void Hashtable_put(Hashtable* this, int key, void* value); void* Hashtable_remove(Hashtable* this, int key); //#include inline void* Hashtable_get(Hashtable* this, int key); void Hashtable_foreach(Hashtable* this, Hashtable_PairFunction f, void* userData); #endif