17 string_view svFunction,
19 string_view svMessage)
21 for (
auto& stream : m_Streams)
22 stream->log(
category, eVerbosity, svFile, svFunction, nLine, svMessage);
25 template<
class... args_t>
26 requires(log_acceptable_args_c<args_t...>)
31 string_view svFunction,
37 for (
auto& stream : m_Streams)
38 stream->log(
category, eVerbosity, svFile, svFunction, nLine, sLogMessage);
43 for (
auto& stream : m_Streams)
47 template<sbo_poly_assignable_c<base_logger_stream> stream_t>
50 m_Streams.emplace_back(std::move(stream));
62 string_view svFunction)
const noexcept
64 for (
const auto& stream : m_Streams)
65 if (stream->get_unit_info(
category, eVerbosity, svFile, svFunction))
requires static format_acceptable_args_c< char_type, args_t... > basic_string static_format(const format_string_type< std::type_identity_t< args_t >... > sFormat, args_t &&... args)
Create a string by formatting it with the format string and the args.
A category is a class that identifies a particular piece of code. This code can be located in differe...
void add_stream(stream_t stream) noexcept
Add an output stream to the logger.
void log(const category &category, verbosity eVerbosity, string_view svFile, string_view svFunction, int nLine, string_view svMessage)
Log to all streams.
bool will_any_stream_accept(const category &category, verbosity eVerbosity, string_view svFile, string_view svFunction) const noexcept
Returns true if any of streams will accept this message.
void reset() noexcept
Reset logger and clear all streams.
void flush()
Flush all streams.
requires(same_variadic_args_v< args_t... >) const expr auto coalesce(args_t &&... args)
Coalesce function, C# a ?? b analogue.