TORCS  1.3.9
The Open Racing Car Simulator
hashtable.h
Go to the documentation of this file.
1 /*
2 The contents of this file are subject to the Mozilla Public License
3 Version 1.0 (the "License"); you may not use this file except in
4 compliance with the License. You may obtain a copy of the License at
5 http://www.mozilla.org/MPL/
6 
7 Software distributed under the License is distributed on an "AS IS"
8 basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
9 License for the specific language governing rights and limitations
10 under the License.
11 
12 The Original Code is expat.
13 
14 The Initial Developer of the Original Code is James Clark.
15 Portions created by James Clark are Copyright (C) 1998
16 James Clark. All Rights Reserved.
17 
18 Contributor(s):
19 $Id$
20 */
21 
22 
23 #include <stddef.h>
24 
25 #ifdef XML_UNICODE
26 typedef const wchar_t *KEY;
27 #else
28 typedef const char *KEY;
29 #endif
30 
31 typedef struct {
33 } NAMED;
34 
35 typedef struct {
36  NAMED **v;
37  size_t size;
38  size_t used;
39  size_t usedLim;
40 } HASH_TABLE;
41 
42 NAMED *lookup(HASH_TABLE *table, KEY name, size_t createSize);
45 
46 typedef struct {
47  NAMED **p;
50 
void hashTableDestroy(HASH_TABLE *)
NAMED * lookup(HASH_TABLE *table, KEY name, size_t createSize)
const char * KEY
Definition: hashtable.h:28
size_t used
Definition: hashtable.h:38
NAMED * hashTableIterNext(HASH_TABLE_ITER *)
void hashTableInit(HASH_TABLE *)
KEY name
Definition: hashtable.h:32
size_t size
Definition: hashtable.h:37
NAMED ** p
Definition: hashtable.h:47
NAMED ** v
Definition: hashtable.h:36
void hashTableIterInit(HASH_TABLE_ITER *, const HASH_TABLE *)
NAMED ** end
Definition: hashtable.h:48
size_t usedLim
Definition: hashtable.h:39