166 log(
const log&) =
delete;
167 log& operator=(
const log&) =
delete;
169 log& operator=(log&&) =
delete;
170 ~log() noexcept = default;
179 void(spdlog::source_loc, spdlog::level::level_enum, fmt::string_view, fmt::format_args)>;
189 template<typename... Args>
191 spdlog::source_loc loc,
192 spdlog::level::level_enum lvl,
193 fmt::format_string<Args...> fmt,
197 vlogger(
module, loc, lvl, fmt, fmt::make_format_args(args...));
214 static void set_log_level(
const std::string& level);
230 void setup_loggers();
249 spdlog::source_loc loc,
250 spdlog::level::level_enum lvl,
251 fmt::string_view fmt,
252 fmt::format_args args)
257 std::mutex _config_mutex;
258 std::vector<std::string> _enabled_modules;
259 bool _is_enabled =
false;
260 std::map<std::pair<module, spdlog::level::level_enum>,
log_func>
static void logger(module module, spdlog::source_loc loc, spdlog::level::level_enum lvl, fmt::format_string< Args... > fmt, const Args &... args)
Templated wrapper for type-safe logging.
Definition log.h:190
std::function< void(spdlog::source_loc, spdlog::level::level_enum, fmt::string_view, fmt::format_args)> log_func
Function type for logging operations.
Definition log.h:178
module
Enumeration of available logging modules.
Definition log.h:33
@ ct2klib
CT2KLib Compatibility module.
Definition log.h:42