summaryrefslogtreecommitdiff
path: root/src/cairo-hash-private.h
diff options
context:
space:
mode:
authorBehdad Esfahbod <behdad@behdad.org>2007-04-21 03:35:07 -0400
committerBehdad Esfahbod <behdad@behdad.org>2007-04-21 03:35:07 -0400
commit737d20a5702a18a1480c3b45f876e886b82b065c (patch)
treeee3586c2b91ed08de9b4da59f1036344db05acf5 /src/cairo-hash-private.h
parent51ce92c3db093c8d26c8002ddbc105b11e7607bf (diff)
downloadcairo-737d20a5702a18a1480c3b45f876e886b82b065c.tar.gz
Move cairo_hash_entry_t to cairo-types-private.h
Diffstat (limited to 'src/cairo-hash-private.h')
-rw-r--r--src/cairo-hash-private.h38
1 files changed, 0 insertions, 38 deletions
diff --git a/src/cairo-hash-private.h b/src/cairo-hash-private.h
index b3593df56..8ed3ba83a 100644
--- a/src/cairo-hash-private.h
+++ b/src/cairo-hash-private.h
@@ -46,44 +46,6 @@
* monolithic cairoint.h. So, for now, just include cairoint.h instead
* if you want to include this file. */
-/**
- * cairo_hash_entry_t:
- *
- * A #cairo_hash_entry_t contains both a key and a value for
- * cairo_hash_table_t. User-derived types for cairo_hash_entry_t must
- * be type-compatible with this structure (eg. they must have an
- * unsigned long as the first parameter. The easiest way to get this
- * is to use:
- *
- * typedef _my_entry {
- * cairo_hash_entry_t base;
- * ... Remainder of key and value fields here ..
- * } my_entry_t;
- *
- * which then allows a pointer to my_entry_t to be passed to any of
- * the cairo_hash_table functions as follows without requiring a cast:
- *
- * _cairo_hash_table_insert (hash_table, &my_entry->base);
- *
- * IMPORTANT: The caller is reponsible for initializing
- * my_entry->base.hash with a hash code derived from the key. The
- * essential property of the hash code is that keys_equal must never
- * return TRUE for two keys that have different hashes. The best hash
- * code will reduce the frequency of two keys with the same code for
- * which keys_equal returns FALSE.
- *
- * Which parts of the entry make up the "key" and which part make up
- * the value are entirely up to the caller, (as determined by the
- * computation going into base.hash as well as the keys_equal
- * function). A few of the cairo_hash_table functions accept an entry
- * which will be used exclusively as a "key", (indicated by a
- * parameter name of key). In these cases, the value-related fields of
- * the entry need not be initialized if so desired.
- **/
-typedef struct _cairo_hash_entry {
- unsigned long hash;
-} cairo_hash_entry_t;
-
typedef cairo_bool_t
(*cairo_hash_keys_equal_func_t) (const void *key_a, const void *key_b);