diff options
Diffstat (limited to 'src/crepe/api/Config.h')
-rw-r--r-- | src/crepe/api/Config.h | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/src/crepe/api/Config.h b/src/crepe/api/Config.h new file mode 100644 index 0000000..f47f45b --- /dev/null +++ b/src/crepe/api/Config.h @@ -0,0 +1,40 @@ +#pragma once + +#include "../util/log.h" + +namespace crepe::api { + +class Config { +private: + Config() = default; +public: + ~Config() = default; + +public: + //! Retrieve handle to global Config instance + static Config & get_instance() { + static Config instance; + return instance; + } + +public: + //! Logging-related settings + struct { + /** + * \brief Log level + * + * Only messages with equal or higher priority than this value will be + * logged. + */ + util::log_level level = util::log_level::INFO; + /** + * \brief Colored log output + * + * Enables log coloring using ANSI escape codes. + */ + bool color = true; + } log; +}; + +} + |