ConsoleSink Class
LogSink implementation that writes to standard output. More...
Declaration
Base class
| class | helios::util::log::LogSink |
Public Member Functions Index
| SinkTypeId | typeId () const noexcept override |
|
Returns the unique type identifier for this sink. More... | |
| void | write (LogLevel level, const std::string &scope, const std::string &message) override |
|
Writes a formatted log message to stdout. More... | |
| void | flush () override |
|
Flushes the stdout buffer. More... | |
Public Static Attributes Index
| static constexpr SinkTypeId | TYPE_ID = "console" |
|
Unique type identifier for this sink. More... | |
Description
LogSink implementation that writes to standard output.
This is the default sink for console-based logging. Output is formatted with level prefix and scope tag, mirroring the original Logger behavior.
Definition at line 23 of file ConsoleSink.ixx.
Public Member Functions
flush()
| inline virtual |
Flushes the stdout buffer.
Definition at line 61 of file ConsoleSink.ixx.
typeId()
| inline nodiscard noexcept virtual |
Returns the unique type identifier for this sink.
- Returns
"console".
Definition at line 36 of file ConsoleSink.ixx.
Reference TYPE_ID.
write()
| inline virtual |
Writes a formatted log message to stdout.
- Parameters
-
level The severity level of the message.
scope The source scope/module name.
message The log message text.
Definition at line 47 of file ConsoleSink.ixx.
References helios::util::log::Debug, helios::util::log::Error, helios::util::log::Info and helios::util::log::Warn.
Public Static Attributes
TYPE_ID
| constexpr static |
Unique type identifier for this sink.
Definition at line 29 of file ConsoleSink.ixx.
Referenced by typeId.
The documentation for this class was generated from the following file:
Generated via doxygen2docusaurus 2.0.0 by Doxygen 1.15.0.