|
TachyonUI 0.1.0
High-performance UI for building tools.
|
#include <stdint.h>#include <string_view>Go to the source code of this file.
Namespaces | |
| namespace | tachyon |
| namespace | tachyon::Hash |
Functions | |
| constexpr uint64_t | tachyon::Hash::CalculateConst (std::string_view str, uint64_t hash=Basis) |
| FNV-1a hash of str, usable at compile time; hash continues an earlier hash. | |
| uint64_t | tachyon::Hash::Calculate (std::string_view str) |
| FNV-1a hash of str; same result as CalculateConst. | |
| uint64_t | tachyon::Hash::CalculateBytes (const void *data, size_t len) |
| FNV-1a hash of len bytes at data. | |
| template<typename T, typename = std::enable_if_t<std::is_trivially_copyable_v<std::decay_t<T>> && !std::is_pointer_v<std::decay_t<T>> && !std::is_same_v<std::decay_t<T>, std::string_view>>> | |
| uint64_t | tachyon::Hash::Calculate (const T &value) |
| FNV-1a hash of a trivially-copyable value's bytes, padding included. | |
| constexpr uint64_t | tachyon::Hash::Combine (uint64_t a, uint64_t b) |
| Order-dependent combine; repeated values don't cancel out. | |
| template<typename... Args> | |
| constexpr uint64_t | tachyon::Hash::Combine (const Args &... args) |
| Combines the Calculate hashes of args, in order. | |
Variables | |
| constexpr uint64_t | tachyon::Hash::Basis = 14695981039346656037ULL |
| FNV-1a 64-bit offset basis (Prime is the FNV-1a prime). | |
| constexpr uint64_t | tachyon::Hash::Prime = 1099511628211ULL |