X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=blobdiff_plain;ds=sidebyside;f=pdf%2Fgoo%2FGHash.h;h=4a6e08d68965d2c5ac360c89c55d474c75bbece0;hb=42ddc3073ecb88271a0ffc74326878627d71b34e;hp=91d970068da38be2e09cad33585b59edf18396cf;hpb=2a393c134fe3fe8eb85bf818cb7ad6ae4396322a;p=evince.git diff --git a/pdf/goo/GHash.h b/pdf/goo/GHash.h index 91d97006..4a6e08d6 100644 --- a/pdf/goo/GHash.h +++ b/pdf/goo/GHash.h @@ -2,14 +2,16 @@ // // GHash.h // -// Copyright 2001-2002 Glyph & Cog, LLC +// Copyright 2001-2003 Glyph & Cog, LLC // //======================================================================== #ifndef GHASH_H #define GHASH_H -#ifdef __GNUC__ +#include + +#ifdef USE_GCC_PRAGMAS #pragma interface #endif @@ -27,17 +29,24 @@ public: GHash(GBool deleteKeysA = gFalse); ~GHash(); void add(GString *key, void *val); + void add(GString *key, int val); void *lookup(GString *key); + int lookupInt(GString *key); void *lookup(char *key); + int lookupInt(char *key); void *remove(GString *key); + int removeInt(GString *key); void *remove(char *key); + int removeInt(char *key); int getLength() { return len; } void startIter(GHashIter **iter); GBool getNext(GHashIter **iter, GString **key, void **val); + GBool getNext(GHashIter **iter, GString **key, int *val); void killIter(GHashIter **iter); private: + void expand(); GHashBucket *find(GString *key, int *h); GHashBucket *find(char *key, int *h); int hash(GString *key);