| libER 0.1.4.2
    ELDEN RING API library | 
Simple structure that holds a string pointer and a hash of the string. More...
#include <text.hpp>
| Public Member Functions | |
| string_hash () | |
| Construct a new string hash object. | |
| string_hash (const wchar_t *str) | |
| Construct a new string hash object. | |
| void | may_change () noexcept | 
| Request a lazy rehash if the string may change. | |
| template<typename T > | |
| int | get_hash (const T &str) noexcept | 
| Get the hash of the string. | |
| template<typename T > | |
| int | hash_string (const T &str) noexcept | 
| Hash the string and get the hash. | |
| void | set_string_ptr (const wchar_t *new_ptr) | 
| Set the underlying string pointer of the hash. | |
Simple structure that holds a string pointer and a hash of the string.
The string is rehashed after the string could have changed (non-const access). The hash is 32 bits in size.
Construct a new string hash object.
| str | the string | 
Get the hash of the string.
| T | type of the string | 
Hash the string and get the hash.
Differs from get_hash in that it always rehashes the string, while get_hash may return a cached result if the string has not changed.
The implementation mirrors ELDEN RING's string hashing and produces equivalent hashes for the same strings.
| T | type of the string | 
Set the underlying string pointer of the hash.
| new_ptr | new pointer to use |