CheatMenuSA/src/utils/log.cpp

33 lines
601 B
C++
Raw Normal View History

2022-06-15 06:45:43 -04:00
#include "log.h"
#include "pch.h"
void Log::AppendLogLevel(std::string& text) noexcept
{
switch (level)
{
case eLogLevel::Debug:
text = "[Debug] " + text;
break;
case eLogLevel::Error:
text = "[Error] " + text;
break;
case eLogLevel::Info:
text = "[Info] " + text;
break;
case eLogLevel::Warn:
text = "[Warn] " + text;
break;
default:
break;
}
}
void Log::SetName(const char* logName) noexcept
{
name = logName;
}
void Log::SetLogLevel(eLogLevel logLevel) noexcept
{
level = logLevel;
}