You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

76 lines
1.8 KiB
C++

#pragma once
#include "fmt/format.h"
#include "DllDefines.h"
#ifdef LEGACY_LOGGER
#include "LegacyDebugLog.h"
#include "LegacyDebugLogTiming.h"
#include "LegacyGuiEventLog.h"
extern UTILITYDLL CLegacyDebugLog mitechDebug;
extern UTILITYDLL CLegacyDebugLogTiming mitechDebugLogTiming;
extern UTILITYDLL CLegacyGuiEventLog mitechGuiEventLog;
#else
#include "MitechDebugLog.h"
#include "MitechDebugLogTiming.h"
#include "MitechGuiEventLog.h"
extern UTILITYDLL CMitechDebugLog mitechDebug;
extern UTILITYDLL CMitechDebugLogTiming mitechDebugLogTiming;
extern UTILITYDLL CMitechGuiEventLog mitechGuiEventLog;
#endif
//
template <typename... Args>
void DebugLog(fmt::format_string<Args...> _fmt, Args&&... args)
{
mitechDebug.Log(_fmt, args...);
}
template <typename... Args>
void DebugLogTrace(bool bTraceData, fmt::format_string<Args...> _fmt, Args&&... args)
{
if (bTraceData)
{
mitechDebug.Log(_fmt, args...);
}
}
template <typename... Args>
void DebugLogTiming(fmt::format_string<Args...> _fmt, Args&&... args)
{
mitechDebugLogTiming.Log(_fmt, args...);
}
template <typename... Args>
void DebugLogTimingTrace(bool bTraceData, fmt::format_string<Args...> _fmt, Args&&... args)
{
if (bTraceData)
{
mitechDebugLogTiming.Log(_fmt, args...);
}
}
template <typename... Args>
void GUIEventLog(fmt::format_string<Args...> _fmt, Args&&... args)
{
mitechGuiEventLog.Log(_fmt, args...);
}
void UTILITYDLL ShutdownLogging();
void UTILITYDLL StartDebugLog();
void UTILITYDLL StopDebugLog();
void UTILITYDLL StartDebugTimingLog();
void UTILITYDLL StopDebugTimingLog();
bool UTILITYDLL IsDebugLogStarted();
bool UTILITYDLL IsDebugLogTimingStarted();
// All GUI Activities Events Log
void UTILITYDLL StartGUIEventLog();
void UTILITYDLL StopGUIEventLog();