The friendly Operating System for the Internet of Things
hashes.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2013 Freie Universität Berlin
3  *
4  * This file is subject to the terms and conditions of the GNU Lesser
5  * General Public License v2.1. See the file LICENSE in the top level
6  * directory for more details.
7  */
8 
20 #ifndef HASHES_H
21 #define HASHES_H
22 
23 #include <stddef.h>
24 #include <inttypes.h>
25 
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
29 
47 uint32_t djb2_hash(const uint8_t *buf, size_t len);
48 
72 uint32_t sdbm_hash(const uint8_t *buf, size_t len);
73 
97 uint32_t kr_hash(const uint8_t *buf, size_t len);
98 
106 uint32_t sax_hash(const uint8_t *buf, size_t len);
107 
119 uint32_t dek_hash(const uint8_t *buf, size_t len);
120 
131 uint32_t fnv_hash(const uint8_t *buf, size_t len);
132 
133 
144 uint32_t rotating_hash(const uint8_t *buf, size_t len);
145 
156 uint32_t one_at_a_time_hash(const uint8_t *buf, size_t len);
157 
158 #ifdef __cplusplus
159 }
160 #endif
161 
163 #endif /* HASHES_H */
uint32_t kr_hash(const uint8_t *buf, size_t len)
Kernighan and Ritchie.
uint32_t one_at_a_time_hash(const uint8_t *buf, size_t len)
One at a time.
uint32_t djb2_hash(const uint8_t *buf, size_t len)
djb2
uint32_t sdbm_hash(const uint8_t *buf, size_t len)
sdbm
uint32_t fnv_hash(const uint8_t *buf, size_t len)
Fowler–Noll–Vo.
uint32_t rotating_hash(const uint8_t *buf, size_t len)
Rotating.
Adds include for missing inttype definitions.
uint32_t sax_hash(const uint8_t *buf, size_t len)
Shift, Add, XOR.
uint32_t dek_hash(const uint8_t *buf, size_t len)
Donald E.