lookup.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef _KJSLOOKUP_H_
00025 #define _KJSLOOKUP_H_
00026
00027 #include <qstring.h>
00028 #include <stdio.h>
00029
00033 struct HashEntry {
00037 const char *s;
00041 int value;
00045 short int attr;
00050 short int params;
00054 const HashEntry *next;
00055 };
00056
00068 struct HashTable {
00072 int type;
00078 int size;
00083 const HashEntry *entries;
00087 int hashSize;
00088 };
00089
00093 class Lookup {
00094 public:
00098 static int find(const struct HashTable *table, const QString& s);
00099 static int find(const struct HashTable *table, const QChar *c, unsigned int len);
00100
00106 static const HashEntry* findEntry(const struct HashTable *table,
00107 const QString &s);
00108 static const HashEntry* findEntry(const struct HashTable *table,
00109 const QChar *c, unsigned int len);
00110
00114 static unsigned int hash(const QString &key);
00115 static unsigned int hash(const QChar *c, unsigned int len);
00116 static unsigned int hash(const char *s);
00117 };
00118
00119 #endif
This file is part of the documentation for KDevelop Version 3.1.2.