2#ifndef GRAMODS_CORE_OSTREAMMESSAGESINK
3#define GRAMODS_CORE_OSTREAMMESSAGESINK
5#include <gmCore/MessageSink.hh>
24 std::lock_guard<std::mutex> guard(lock);
36 std::lock_guard<std::mutex> guard(lock);
47 void setStream(std::string name);
55 void setUseAnsiColor(
bool on);
57 void output(Message msg);
71 std::ostream *raw_out =
nullptr;
72 std::shared_ptr<std::ostream> shared_out;
75 bool use_ansi_color =
false;
This is the base type for back-ends taking care of information sent to the Console class.
Definition MessageSink.hh:23
Definition OStreamMessageSink.hh:14
void setLevel(int l)
Set the level of messages to output.
Definition OStreamMessageSink.hh:65
void setStream(std::ostream *s)
Set the stream to use as output.
Definition OStreamMessageSink.hh:23
void setStream(std::shared_ptr< std::ostream > s)
Set the stream to use as output.
Definition OStreamMessageSink.hh:35