Sound Byte Libs 0.5.1-121-g3358a44
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 * tee_output.hpp — Dual-sink log output template
3 *
4 * Composes two log sinks so every write goes to both.
5 * Works with any type that provides static void write(const char*).
6 */
7
8#ifndef SBL_COMMON_LOG_TEE_OUTPUT_HPP_
9#define SBL_COMMON_LOG_TEE_OUTPUT_HPP_
10
11namespace sbl::log {
12
13template<typename A, typename B>
14struct TeeOutput {
15 static void write(const char* str) {
16 A::write(str);
17 B::write(str);
18 }
19};
20
21} // namespace sbl::log
22
23#endif // SBL_COMMON_LOG_TEE_OUTPUT_HPP_
Logging.
Definition banner.hpp:51
static void write(const char *str)