Orcus
|
#include <tokens.hpp>
Public Member Functions | |
tokens (const tokens &)=delete | |
tokens (const char **token_names, size_t token_name_count) | |
bool | is_valid_token (xml_token_t token) const |
xml_token_t | get_token (std::string_view name) const |
std::string_view | get_token_name (xml_token_t token) const |
XML token store that provides mapping of integral token indentifiers and their original names. Instances of this class are typically used as global constants.
xml_token_t orcus::tokens::get_token | ( | std::string_view | name | ) | const |
Get token from a specified name.
name | textural token name |
std::string_view orcus::tokens::get_token_name | ( | xml_token_t | token | ) | const |
Get textural token name from a token value.
token | numeric token value |
bool orcus::tokens::is_valid_token | ( | xml_token_t | token | ) | const |
Check if a token returned from get_token() method is valid.