CbmRoot
Loading...
Searching...
No Matches
EnumDict.h File Reference
#include <boost/algorithm/string/predicate.hpp>
#include <algorithm>
#include <iosfwd>
#include <optional>
#include <stdexcept>
#include <string_view>
#include <vector>
#include <fmt/format.h>
#include <xpu/defines.h>
Include dependency graph for EnumDict.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  cbm::algo::detail::EnumHasDict< T >
 

Namespaces

namespace  cbm
 
namespace  cbm::algo
 
namespace  cbm::algo::detail
 
namespace  std
 Hash for CbmL1LinkKey.
 

Macros

#define CBM_ENUM_DICT(type, ...)
 

Typedefs

template<typename T >
using cbm::algo::detail::EnumDict_t = std::vector<std::pair<std::string_view, T>>
 

Functions

template<typename T , typename = std::enable_if_t<detail::EnumHasDict_v<T>>>
std::vector< std::string_view > cbm::algo::detail::ValidEntries ()
 
void cbm::algo::detail::RaiseUnknownEntry (std::string_view str, const std::vector< std::string_view > &validEntries)
 
template<typename T , typename = std::enable_if_t<detail::EnumHasDict_v<T>>>
std::optional< T > cbm::algo::FromString (std::string_view str, bool caseSensitive=false)
 
template<typename T , typename = std::enable_if_t<detail::EnumHasDict_v<T>>>
std::string_view cbm::algo::ToString (T t)
 
template<typename T , typename = std::enable_if_t<cbm::algo::detail::EnumHasDict_v<T>>>
std::ostream & std::operator<< (std::ostream &os, T t)
 
template<typename T , typename = std::enable_if_t<cbm::algo::detail::EnumHasDict_v<T>>>
std::istream & std::operator>> (std::istream &is, T &t)
 

Variables

template<typename T >
const EnumDict_t< T > cbm::algo::detail::EnumDict
 
template<typename T >
constexpr bool cbm::algo::detail::EnumHasDict_v = EnumHasDict<T>::value
 

Macro Definition Documentation

◆ CBM_ENUM_DICT

#define CBM_ENUM_DICT ( type,
... )

Definition at line 106 of file EnumDict.h.