LibSWOC++ 1.5.14
Solid Wall of C++
Loading...
Searching...
No Matches
Lexicon.h File Reference
#include <string_view>
#include <initializer_list>
#include <tuple>
#include <functional>
#include <array>
#include <variant>
#include <ctype.h>
#include "swoc/swoc_version.h"
#include "swoc/IntrusiveHashMap.h"
#include "swoc/MemArena.h"
#include "swoc/bwf_base.h"
#include "swoc/ext/HashFNV.h"
Include dependency graph for Lexicon.h:

Go to the source code of this file.

Classes

struct  swoc::detail::lexicon_pair_type< E >
 
class  swoc::Lexicon< E >
 
struct  swoc::Lexicon< E >::Definition
 
class  swoc::Lexicon< E >::base_iterator
 Common features of container iterators. More...
 
class  swoc::Lexicon< E >::value_iterator
 
class  swoc::Lexicon< E >::name_iterator
 
struct  swoc::Lexicon< E >::NameDefaultVisitor
 Visitor functor for handling NameDefault. More...
 
struct  swoc::Lexicon< E >::ValueDefaultVisitor
 Visitor functor for handling ValueDefault. More...
 
struct  swoc::Lexicon< E >::Item
 
class  std::tuple_element< IDX, swoc::detail::lexicon_pair_type< E > >
 
class  std::tuple_element< 0, swoc::detail::lexicon_pair_type< E > >
 
class  std::tuple_element< 1, swoc::detail::lexicon_pair_type< E > >
 

Namespaces

namespace  swoc
 For template deduction guides.
 
namespace  std
 STL namespace.
 

Functions

template<typename... Args>
std::string swoc::detail::what (std::string_view const &fmt, Args &&...args)
 
template<typename E>
size_t swoc::Lexicon_Hash (E e)
 
template<typename E>
BufferWriterswoc::bwformat (BufferWriter &w, bwf::Spec const &spec, Lexicon< E > const &lex)
 
template<size_t IDX, typename E>
auto std::get (swoc::detail::lexicon_pair_type< E > const &p) -> typename std::tuple_element< IDX, swoc::detail::lexicon_pair_type< E > >::type
 

Detailed Description

Assistant class for translating strings to and from enumeration values.

Definition in file Lexicon.h.

Function Documentation

◆ what()

template<typename... Args>
std::string swoc::detail::what ( std::string_view const & fmt,
Args &&... args )

Create an r-value reference to a temporary formatted string.

Template Parameters
ArgsFormat string argument types.
Parameters
fmtFormat string.
argsArguments to format string.
Returns
r-value reference to a std::string containing the formatted string.

This is used when throwing exceptions.

Definition at line 37 of file Lexicon.h.