Sound Byte Libs
0.5.1-340-gab5b79a
C++ firmware library for audio applications on 32-bit ARM Cortex-M processors
Loading...
Searching...
No Matches
tee_output.hpp
Go to the documentation of this file.
1
/**
2
* @file tee_output.hpp
3
* @brief Dual-sink log output template
4
*
5
* Composes two log sinks so every write goes to both.
6
* Works with any type that provides static void write(const char*).
7
*/
8
9
#ifndef SBL_COMMON_LOG_TEE_OUTPUT_HPP_
10
#define SBL_COMMON_LOG_TEE_OUTPUT_HPP_
11
12
namespace
sbl::log
{
13
14
template
<
typename
A,
typename
B>
15
struct
TeeOutput
{
16
static
void
write(
const
char
*
str
) {
17
A::write(
str
);
18
B::write(
str
);
19
}
20
};
21
22
}
// namespace sbl::log
23
24
#endif
// SBL_COMMON_LOG_TEE_OUTPUT_HPP_
sbl::log
Logging.
Definition
banner.hpp:53
sbl::log::is_sink_v
constexpr bool is_sink_v
Definition
sink.hpp:55
sbl::log::TeeOutput
Definition
tee_output.hpp:15
src
sbl
common
log
tee_output.hpp
Generated by
1.9.8