Objectively 1.0.0
Ultra-lightweight object oriented framework for GNU C.
|
Utilities for calculating hash values. More...
#include <Objectively/Object.h>
Go to the source code of this file.
Macros | |
#define | HASH_SEED 13 |
The hash seed value. More... | |
Functions | |
OBJECTIVELY_EXPORT int | HashForBytes (int hash, const uint8_t *bytes, const Range range) |
Accumulates the hash value of bytes into hash . More... | |
OBJECTIVELY_EXPORT int | HashForCharacters (int hash, const char *chars, const Range range) |
Accumulates the hash value of chars into hash . More... | |
OBJECTIVELY_EXPORT int | HashForCString (int hash, const char *chars) |
Accumulates the hash value of the null-terminated string into hash . More... | |
OBJECTIVELY_EXPORT int | HashForDecimal (int hash, const double decimal) |
Accumulates the hash value of decimal into hash . More... | |
OBJECTIVELY_EXPORT int | HashForInteger (int hash, const long integer) |
Accumulates the hash value of integer into hash . More... | |
OBJECTIVELY_EXPORT int | HashForObject (int hash, const ident obj) |
Accumulates the hash value of object into hash . More... | |
Utilities for calculating hash values.
Definition in file Hash.h.
OBJECTIVELY_EXPORT int HashForBytes | ( | int | hash, |
const uint8_t * | bytes, | ||
const Range | range | ||
) |
Accumulates the hash value of bytes
into hash
.
hash | The hash accumulator. |
bytes | The bytes to hash. |
range | The Range to hash. |
Definition at line 28 of file Hash.c.
OBJECTIVELY_EXPORT int HashForCharacters | ( | int | hash, |
const char * | chars, | ||
const Range | range | ||
) |
Accumulates the hash value of chars
into hash
.
hash | The hash accumulator. |
chars | The characters to hash. |
range | The Range to hash. |
Definition at line 45 of file Hash.c.
OBJECTIVELY_EXPORT int HashForCString | ( | int | hash, |
const char * | chars | ||
) |
Accumulates the hash value of the null-terminated string
into hash
.
hash | The hash accumulator. |
chars | The null-terminated C string. |
Definition at line 49 of file Hash.c.
OBJECTIVELY_EXPORT int HashForDecimal | ( | int | hash, |
const double | decimal | ||
) |
OBJECTIVELY_EXPORT int HashForInteger | ( | int | hash, |
const long | integer | ||
) |
OBJECTIVELY_EXPORT int HashForObject | ( | int | hash, |
const ident | obj | ||
) |
Accumulates the hash value of object
into hash
.
hash | The hash accumulator. |
obj | The Object to hash. |