Horizon
Loading...
Searching...
No Matches
Public Member Functions | List of all members
horizon::LutEnumStr< T > Class Template Reference

Public Member Functions

 LutEnumStr (std::initializer_list< std::pair< const std::string, const T > > s)
 
const T lookup (const std::string &s) const
 
const T lookup (const nlohmann::json &j) const
 
const std::optional< T > lookup_opt (const std::string &s) const
 
const T lookup (const std::string &s, T def) const
 
const T lookup (const nlohmann::json &j, T def) const
 
const std::string & lookup_reverse (const T s) const
 

Member Function Documentation

◆ lookup()

template<typename T >
const T horizon::LutEnumStr< T >::lookup ( const std::string &  s) const
inline
Returns
the enum corresponding to string s

◆ lookup_reverse()

template<typename T >
const std::string & horizon::LutEnumStr< T >::lookup_reverse ( const T  s) const
inline
Returns
the string corresponding to enum s

The documentation for this class was generated from the following file: