proper cmake

This commit is contained in:
2023-06-04 16:10:06 +02:00
parent 13a8b4c35d
commit fdcb0cf0c4
154 changed files with 1273 additions and 1620 deletions

19
src/utils/srcs/Logger.cpp Normal file
View File

@@ -0,0 +1,19 @@
//
// Created by Stepan Usatiuk on 23.05.2023.
//
#include "../includes/Logger.h"
Logger::Logger(int level, std::ostream &out) : loglevel(level), out(out) {
}
void Logger::write(const std::string &what, int whatlevel) {
if (whatlevel <= loglevel) {
std::lock_guard outLock(outM);
out.get() << what << std::flush;
}
}
void Logger::setLevel(int level) {
loglevel = level;
}