Zappy Server
C++ game server: world, rules, scheduler, network
Loading...
Searching...
No Matches
ILogSink.hpp
Go to the documentation of this file.
1
#pragma once
2
3
#include <string>
4
5
enum class
LogLevel
{
Debug
= 0,
Info
,
Warn
,
Error
};
6
14
class
ILogSink
{
15
public
:
16
virtual
~ILogSink
() =
default
;
17
19
virtual
void
write
(
LogLevel
level,
const
std::string& line) = 0;
20
};
LogLevel
LogLevel
Definition
ILogSink.hpp:5
LogLevel::Info
@ Info
LogLevel::Warn
@ Warn
LogLevel::Error
@ Error
LogLevel::Debug
@ Debug
ILogSink
Output destination for a fully-formatted log line (Strategy pattern).
Definition
ILogSink.hpp:14
ILogSink::~ILogSink
virtual ~ILogSink()=default
ILogSink::write
virtual void write(LogLevel level, const std::string &line)=0
Write one already-formatted line if level passes the sink's threshold.
server
src
logging
ILogSink.hpp
Generated by
1.9.8