MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/PositionBasedDynamics / ConsoleSink

Class ConsoleSink

Utils/Logger.h:28–48  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

26 };
27
28 class ConsoleSink : public LogSink
29 {
30 public:
31 ConsoleSink(const LogLevel minLevel) : LogSink(minLevel) {}
32
33 virtual void write(const LogLevel level, const std::string &str)
34 {
35 if (level < m_minLevel)
36 return;
37
38// if (level == LogLevel::INFO)
39// std::cout << "Info: ";
40// else
41 if (level == LogLevel::WARN)
42 std::cout << "Warning: ";
43 else if (level == LogLevel::ERR)
44 std::cerr << "Error: ";
45
46 std::cout << str << std::endl;
47 }
48 };
49
50 class FileSink : public LogSink
51 {

Callers 1

UtilitiesModuleFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected