comparison clustalomega/clustal-omega-0.2.0/src/squid/gki.h @ 0:ff1768533a07

Migrated tool version 0.2 from old tool shed archive to new tool shed repository
author clustalomega
date Tue, 07 Jun 2011 17:04:25 -0400
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:ff1768533a07
1 /*****************************************************************
2 * SQUID - a library of functions for biological sequence analysis
3 * Copyright (C) 1992-2002 Washington University School of Medicine
4 *
5 * This source code is freely distributed under the terms of the
6 * GNU General Public License. See the files COPYRIGHT and LICENSE
7 * for details.
8 *****************************************************************/
9
10 #ifndef SQUID_GKI_INCLUDED
11 #define SQUID_GKI_INCLUDED
12
13 /* gki.h
14 * SRE, Sat May 1 15:07:22 1999
15 *
16 * Declarations of structures, functions for generic key index
17 * module: emulation of Perl hashes. See gki.c.
18 *
19 * RCS $Id: gki.h 217 2011-03-19 10:27:10Z andreas $ (Original squid RCS Id: gki.h,v 1.2 1999/07/15 22:30:45 eddy Exp)
20 */
21
22 /* gki_elem:
23 * key, array index pairs are kept in linked list structures.
24 */
25 struct gki_elem {
26 char *key;
27 int idx;
28 struct gki_elem *nxt;
29 };
30
31 /* gki:
32 * a dynamically resized hash structure;
33 * contains a hash table and associated data
34 */
35 typedef struct {
36 struct gki_elem **table;
37
38 int primelevel;
39 int nhash;
40 int nkeys;
41 } GKI;
42
43 GKI *GKIInit(void);
44 void GKIFree(GKI *hash);
45 int GKIHashValue(GKI *hash, char *key);
46 int GKIStoreKey(GKI *hash, char *key);
47 int GKIKeyIndex(GKI *hash, char *key);
48 void GKIStatus(GKI *hash);
49
50 #endif /* SQUID_GKI_INCLUDED */