-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathLogger.h
38 lines (31 loc) · 946 Bytes
/
Logger.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#pragma once
#include "buildconfig.h"
#include <cstdio>
#include <cstdarg>
#include <Windows.h>
#include <string>
namespace Logger
{
enum Level {
LOG_DEBUG, LOG_INFO, LOG_WARN, LOG_ERROR, LOG_FATAL, LOG_NONE
};
void printLog(Level level, const char *str);
void log(Level level, const char *format, ...);
void noln(Level level, const char *format, ...);
void putc(Level level, char c);
void flush(Level level);
void setLevel(Level level);
Level getLevel();
bool isEnabled();
void debug(const char *format, ...);
void printDebug(const char *str);
void info(const char *format, ...);
void printInfo(const char *str);
void warn(const char *format, ...);
void printWarn(const char *str);
void error(const char *format, ...);
void printError(const char *str);
void fatal(const char *format, ...);
void printFatal(const char *str);
void cleanup();
};