class
#include <Core/Logger.h>
Logger Logger enqueues trace items for processing.
This class should not usually be used directly.
Constructors, destructors, conversion operators
Public functions
- auto operator=(Logger const&) -> Logger& deleted
- void AttachSink(ITraceSink* sink)
- Registers the sink.
- void RemoveSink(ITraceSink* sink)
- Unregisters the sink.
-
auto Write(TraceLevel level,
const char* functionName,
const char* message,
std::
uint32_t messageLength) -> bool - Writes the specified entry to all sinks.
-
void Flush(std::
uint32_t sleepDurationNs = 100) noexcept - Flushes and waits until all prior entries are written to all sinks.
-
void InitializeBacktrace(std::
uint32_t maxCapacity, TraceLevel flushLevel = TraceLevel:: Unknown) - Initializes backtrace storage to be able to use TraceLevel::
Deferred. - void FlushBacktraceAsync() noexcept
- Writes any stored deferred entries to all sinks asynchronously.
-
void ShrinkThreadLocalQueue(std::
size_t capacity) noexcept - Shrinks the thread-local queue to the specified target capacity.
-
auto GetThreadLocalQueueCapacity() -> std::
size_t noexcept - Returns the current capacity of the thread-local queue.