file
Configuration.h
Namespaces
- namespace esp
- Root namespace.
- namespace esp::core
- Core Habitat functionality.
- namespace esp::core::config
- Configuration functionality.
Classes
- class esp::core::config::ConfigValue
- This class uses an anonymous tagged union to store values of different types, as well as providing access to the values in a type safe manner.
- class esp::core::config::Configuration
- This class holds configuration data in a map of ConfigValues, and also supports nested configurations via a map of smart pointers to this type.
Enums
- enum class ConfigStoredType { Unknown = ID_UNDEFINED, Boolean, Integer, Double, MagnumVec2, MagnumVec3, MagnumVec4, MagnumMat3, MagnumQuat, MagnumRad, _nonTrivialTypes, String = _nonTrivialTypes }
- This enum lists every type of value that can be currently stored directly in an esp::
core:: config:: Configuration. All supported types should have entries in this enum class. All non-trivial types should have their enums placed below _nonTrivialTypes
tag.
Functions
-
auto getNameForStoredType(const ConfigStoredType& value) -> std::
string - Retrieve a string description of the passed ConfigStoredType enum value.
- auto isConfigStoredTypeNonTrivial(ConfigStoredType type) -> bool constexpr
- Quick check to see if type is trivial or not.
-
template<class T>auto configStoredTypeFor() -> ConfigStoredType constexpr
- Function template to return type enum for specified type. All supported types should have a specialization of this function handling their type to ConfigStoredType enum tags mapping.
-
template<>auto configStoredTypeFor<bool>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
Boolean type enum for specified type. -
template<>auto configStoredTypeFor<int>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
Integer type enum for specified type. -
template<>auto configStoredTypeFor<double>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
Double type enum for specified type. -
template<>auto configStoredTypeFor<Mn::Vector2>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
MagnumVec2 type enum for specified type. -
template<>auto configStoredTypeFor<Mn::Vector3>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
MagnumVec3 type enum for specified type. -
template<>auto configStoredTypeFor<Mn::Color3>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
MagnumVec3 type enum for specified type. -
template<>auto configStoredTypeFor<Mn::Vector4>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
MagnumVec4 type enum for specified type. -
template<>auto configStoredTypeFor<Mn::Color4>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
MagnumVec4 type enum for specified type. -
template<>auto configStoredTypeFor<Mn::Matrix3>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
MagnumMat3 type enum for specified type. -
template<>auto configStoredTypeFor<Mn::Quaternion>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
MagnumQuat type enum for specified type. -
template<>auto configStoredTypeFor<Mn::Rad>() -> ConfigStoredType constexpr
- Returns ConfigStoredType::
MagnumRad type enum for specified type. -
auto operator<<(Mn::
Debug& debug, const ConfigStoredType& value) -> MAGNUM_EXPORT Mn:: Debug& - Stream operator to support display of ConfigStoredType enum tags.
- auto operator!=(const ConfigValue& a, const ConfigValue& b) -> bool
- Inequality Comparison.
-
auto operator<<(Mn::
Debug& debug, const ConfigValue& value) -> MAGNUM_EXPORT Mn:: Debug& - provide debug stream support for ConfigValue
-
auto operator<<(Mn::
Debug& debug, const Configuration& value) -> MAGNUM_EXPORT Mn:: Debug& - provide debug stream support for a Configuration