equal
deleted
inserted
replaced
22 * |
22 * |
23 */ |
23 */ |
24 #include "precompiled.hpp" |
24 #include "precompiled.hpp" |
25 #include "logging/logDecorations.hpp" |
25 #include "logging/logDecorations.hpp" |
26 #include "logging/logLevel.hpp" |
26 #include "logging/logLevel.hpp" |
|
27 #include "logging/logMessageBuffer.hpp" |
27 #include "logging/logOutput.hpp" |
28 #include "logging/logOutput.hpp" |
28 #include "logging/logTag.hpp" |
29 #include "logging/logTag.hpp" |
29 #include "logging/logTagSet.hpp" |
30 #include "logging/logTagSet.hpp" |
30 #include "memory/allocation.inline.hpp" |
31 #include "memory/allocation.inline.hpp" |
31 |
32 |
72 for (LogOutputList::Iterator it = _output_list.iterator(level); it != _output_list.end(); it++) { |
73 for (LogOutputList::Iterator it = _output_list.iterator(level); it != _output_list.end(); it++) { |
73 (*it)->write(decorations, msg); |
74 (*it)->write(decorations, msg); |
74 } |
75 } |
75 } |
76 } |
76 |
77 |
|
78 void LogTagSet::log(const LogMessageBuffer& msg) { |
|
79 LogDecorations decorations(LogLevel::Invalid, *this, _decorators); |
|
80 for (LogOutputList::Iterator it = _output_list.iterator(msg.least_detailed_level()); it != _output_list.end(); it++) { |
|
81 (*it)->write(msg.iterator(it.level(), decorations)); |
|
82 } |
|
83 } |
|
84 |
77 int LogTagSet::label(char* buf, size_t len, const char* separator) const { |
85 int LogTagSet::label(char* buf, size_t len, const char* separator) const { |
78 int tot_written = 0; |
86 int tot_written = 0; |
79 for (size_t i = 0; i < _ntags; i++) { |
87 for (size_t i = 0; i < _ntags; i++) { |
80 int written = jio_snprintf(buf + tot_written, len - tot_written, "%s%s", |
88 int written = jio_snprintf(buf + tot_written, len - tot_written, "%s%s", |
81 (i == 0 ? "" : separator), |
89 (i == 0 ? "" : separator), |