#include <bsa/detail/common.hpp>
template<class Hash, hasher_ t<Hash> Hasher>
key class
A generic key used to uniquely identify an object inside the virtual filesystem.
Template parameters | |
---|---|
Hash | The hash type used as the underlying key. |
Hasher | The function used to generate the hash. |
Assignment
Comparison
-
auto operator<=>(const key& a_lhs,
const key& a_rhs) -> std::
strong_ordering noexcept -
auto operator<=>(const key& a_lhs,
const hash_
type& a_rhs) -> std:: strong_ordering noexcept - auto operator==(const key& a_lhs, const key& a_rhs) -> bool noexcept
-
auto operator==(const key& a_lhs,
const hash_
type& a_rhs) -> bool noexcept
Constructors
Destructor
- ~key() defaulted noexcept
Member types
- using hash_type = Hash
- The underlying hash type.
Observers
-
auto hash() const -> const hash_
type& noexcept - Retrieve a reference to the underlying hash.
-
auto name() const -> std::
string_view noexcept - Retrieve the name that generated the underlying hash.
Function documentation
bsa:: components:: key<Hash, Hasher>:: key(String&& a_string) noexcept
Construct a key using a string-like object.
Parameters | |
---|---|
a_string | The string-like object used to generate the underlying hash. |