#include <bits/types/wint_t.h>
#include <dcl/String.h>
Go to the source code of this file.
◆ __DCL_HASH_FUN_H__
#define __DCL_HASH_FUN_H__ 20110303 |
◆ __byte_string_hashKey()
unsigned int __byte_string_hashKey |
( |
const char * | _psz | ) |
|
|
inline |
Definition at line 56 of file HashFun.h.
57{
58 unsigned int h = 0;
59 for( ; *_psz; _psz++)
60 {
61 h = 5 * h + (unsigned char) *_psz;
62 }
63 return h;
64}
◆ __wide_string_hashKey()
unsigned int __wide_string_hashKey |
( |
const wchar_t * | _psz | ) |
|
|
inline |
Definition at line 19 of file HashFun.h.
20{
21 unsigned int h = 0;
22 for( ; *_psz; _psz++)
23 {
24 h = 5 * h + (wint_t) *_psz;
25 }
26 return h;
27}
◆ DCLGetNextPrimNumber()
DCLCAPI size_t DCLGetNextPrimNumber |
( |
size_t | _n | ) |
|
Definition at line 23 of file HashFun.cpp.
24{
26 for(
size_t i = 0; i <
n; i++)
27 {
28 if (_n < __prim_numbers[i])
29 return __prim_numbers[i];
30 }
31 return __prim_numbers[
n - 1];
32}
#define __countof(array, type)
void CharsetConvertException *size_t n