![]() |
ATLAS Offline Software
|
Maintain a mapping of strings to 64-bit ints. More...
#include <stdint.h>#include <string>#include <memory>Go to the source code of this file.
Classes | |
| class | SG::StringPool |
Namespaces | |
| namespace | SG |
| Forward declaration. | |
Maintain a mapping of strings to 64-bit ints.
We map from strings to integer keys using a hash function. We keep a table of hashed strings so that we can later return the string given the key. We allow registering additional key->string mappings as well, as long as there aren't collisions. We also keep an auxiliary int that gets hashed along with the string.
A string can be marked as ‘transient’ (using SG::transientKey). If we encounter a hash collision while inserting a transient key, we do not fail, but instead use find an alternate hash for it.
Definition in file StringPool.h.