14#include "spdlog/spdlog.h"
15#include "spdlog/common.h"
16#include "spdlog/sinks/basic_file_sink.h"
19#if _MSVC_LANG > 201402L
21namespace fs = std::filesystem;
23#include <experimental/filesystem>
24namespace fs = std::experimental::filesystem;
27#include "MaxUsd/MaxUSDAPI.h"
31#pragma warning(disable : 4251)
33namespace MAXUSD_NS_DEF {
39 static std::shared_ptr<spdlog::logger> spdLogger;
42 static const size_t maxLogSize = 1048576 * 200;
44 static const size_t maxLogFiles = 5;
65 Level level = Level::Off;
77 static void Message(
Level messageType,
const std::wstring& message);
82 template<
typename FormatString,
typename... Args>
83 static void Warn(
const FormatString &fmt,
const Args &... args)
85 if (spdLogger && !paused) {
86 spdLogger->warn(fmt, args...);
90 template<
typename FormatString,
typename... Args>
91 static void Info(
const FormatString &fmt,
const Args &... args)
93 if (spdLogger && !paused) {
94 spdLogger->info(fmt, args...);
98 template<
typename FormatString,
typename... Args>
99 static void Error(
const FormatString &fmt,
const Args &... args)
101 if (spdLogger && !paused) {
102 spdLogger->error(fmt, args...);
Simple wrapper for some basic logging functionality provided by the spdlog library.
Definition: Logging.h:36
Level
logging severity level for filtering \comment value of enum is important as it reflects the index in ...
Definition: Logging.h:55