21 #ifndef mia_core_threadedmsg_hh
22 #define mia_core_threadedmsg_hh
64 template <
typename OS>
65 static void set_master_stream(OS& master);
67 template <
typename OS,
typename placeholder>
friend struct __dispatch_set_master_stream;
69 static void do_set_master_stream(std::ostream& master);
90 template <
typename OS,
typename placeholder>
91 struct __dispatch_set_master_stream {
92 static void apply(OS& master)
94 CThreadMsgStream::do_set_master_stream(master);
99 template <
typename placeholder>
103 static_assert(
sizeof(placeholder) == 0,
104 "CThreadMsgStream can't be used as master stream because it would deadlock.");
110 template <
typename OS>
113 __dispatch_set_master_stream<OS, int>::apply(master);
This class is used to handle syncronizized output of logging output in a multi-threaded environment.
static void set_master_stream(OS &master)
#define NS_MIA_BEGIN
conveniance define to start the mia namespace
#define EXPORT_CORE
Macro to manage Visual C++ style dllimport/dllexport.
#define NS_MIA_END
conveniance define to end the mia namespace