23#ifndef SGTOOLS_STRINGPOOL_H
24#define SGTOOLS_STRINGPOOL_H
105 const std::string&
str,
unsigned int sgaux_t
Type of auxiliary data.
bool registerKey(sgkey_t key, const std::string &str, sgaux_t aux=0)
Remember an additional mapping from key to string.
std::unique_ptr< StringPoolImpl > m_impl
void dump() const
Debugging dump.
const std::string * keyToString(sgkey_t key) const
Find the string corresponding to a given key.
static const sgkey_t sgkey_t_max
static const int sgkey_t_nbits
Number of bits we'll use in the keys.
size_t size() const
Number of registered mappings.
sgkey_t stringToKey(const std::string &str, sgaux_t aux=0)
Find the key for a string.
uint32_t sgkey_t
Type of the integer keys.
StringPool & operator=(const StringPool &other)
Assignment/move operators.
void clear()
Empty the pool.