~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to include/hash.h

  • Committer: Brian Aker
  • Date: 2008-07-13 18:27:33 UTC
  • Revision ID: brian@tangent.org-20080713182733-3u1et5nrmofi8a8n
my_bool cleanup.

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
/* flags for hash_init */
31
31
#define HASH_UNIQUE     1       /* hash_insert fails on duplicate key */
32
32
 
33
 
typedef uchar *(*hash_get_key)(const uchar *,size_t*,my_bool);
 
33
typedef uchar *(*hash_get_key)(const uchar *,size_t*,bool);
34
34
typedef void (*hash_free_key)(void *);
35
35
 
36
36
typedef struct st_hash {
49
49
 
50
50
#define hash_init(A,B,C,D,E,F,G,H) _hash_init(A,0,B,C,D,E,F,G,H CALLER_INFO)
51
51
#define hash_init2(A,B,C,D,E,F,G,H,I) _hash_init(A,B,C,D,E,F,G,H,I CALLER_INFO)
52
 
my_bool _hash_init(HASH *hash, uint growth_size,CHARSET_INFO *charset,
 
52
bool _hash_init(HASH *hash, uint growth_size,CHARSET_INFO *charset,
53
53
                   ulong default_array_elements, size_t key_offset,
54
54
                   size_t key_length, hash_get_key get_key,
55
55
                   void (*free_element)(void*), uint flags CALLER_INFO_PROTO);
61
61
                HASH_SEARCH_STATE *state);
62
62
uchar *hash_next(const HASH *info, const uchar *key, size_t length,
63
63
                 HASH_SEARCH_STATE *state);
64
 
my_bool my_hash_insert(HASH *info,const uchar *data);
65
 
my_bool hash_delete(HASH *hash,uchar *record);
66
 
my_bool hash_update(HASH *hash,uchar *record,uchar *old_key,size_t old_key_length);
 
64
bool my_hash_insert(HASH *info,const uchar *data);
 
65
bool hash_delete(HASH *hash,uchar *record);
 
66
bool hash_update(HASH *hash,uchar *record,uchar *old_key,size_t old_key_length);
67
67
void hash_replace(HASH *hash, HASH_SEARCH_STATE *state, uchar *new_row);
68
 
my_bool hash_check(HASH *hash);                 /* Only in debug library */
 
68
bool hash_check(HASH *hash);                    /* Only in debug library */
69
69
 
70
70
#define hash_clear(H) bzero((char*) (H),sizeof(*(H)))
71
71
#define hash_inited(H) ((H)->array.buffer != 0)