11#ifndef INCGUARD_MGL_HASH_FNV1A_H_1607309087
12#define INCGUARD_MGL_HASH_FNV1A_H_1607309087
36constexpr uint32_t
FNV1a(
const char *str,
const uint32_t value = Hash::kFNV1aDefaultValue32)
noexcept
43 return FNV1a(&str[1], (value ^
static_cast<uint32_t
>(str[0])) * Hash::kFNV1aPrime32);
55constexpr uint64_t
FNV1a64(
const char *str,
const uint64_t value = Hash::kFNV1aDefaultValue64)
noexcept
62 return FNV1a64(&str[1], (value ^
static_cast<uint64_t
>(str[0])) * Hash::kFNV1aPrime64);
constexpr uint64_t kFNV1aPrime64
64bitハッシュ値の生成に使用する素数
Definition mgl_hash_fnv1a.h:25
constexpr uint32_t kFNV1aPrime32
32bitハッシュ値の生成に使用する素数
Definition mgl_hash_fnv1a.h:21
constexpr uint32_t FNV1a(const char *str, const uint32_t value=Hash::kFNV1aDefaultValue32) noexcept
FNV-1aアルゴリズムで文字列から32bitハッシュ値を取得
Definition mgl_hash_fnv1a.h:36
constexpr uint64_t kFNV1aDefaultValue64
64bitハッシュ値のデフォルト値
Definition mgl_hash_fnv1a.h:23
constexpr uint64_t FNV1a64(const char *str, const uint64_t value=Hash::kFNV1aDefaultValue64) noexcept
FNV-1aアルゴリズムで文字列から64bitハッシュ値を取得
Definition mgl_hash_fnv1a.h:55
constexpr uint32_t kFNV1aDefaultValue32
32bitハッシュ値のデフォルト値
Definition mgl_hash_fnv1a.h:19