Struct COutputLogger::TMsg
Defined in File COutputLogger.h
Nested Relationships
This struct is a nested type of Class COutputLogger.
Struct Documentation
-
struct TMsg
Struct responsible of holding information relevant to the message (in std::string form) issued by the user.
Upon TMsg initialization, instance fetches the name of the caller COutputLogger, as well as the VerbosityLevel and the mrpt::Clock::time_point of the message provided. The format of the message when this is printed / or written to an external file complies is given below:
Public Functions
-
TMsg(const mrpt::system::VerbosityLevel level, std::string_view msg, const COutputLogger &logger)
Class constructor that passes a message in std::string form as well as a reference to the COutputLogger that provided the current message.
-
std::string getAsString() const
Return a string representation of the underlying message.
-
void getAsString(std::string *contents) const
Fill the string with the contents of the underlying message in string representation.
-
void writeToStream(std::ostream &out) const
Write the message contents to the specified stream.
See also
getAsString
-
void dumpToConsole() const
Dump the message contents to the standard output.
See also
writeToStream
Public Members
-
mrpt::Clock::time_point timestamp
Timestamp of the message.
-
VerbosityLevel level
Verbosity level of the message.
-
std::string name
Name of the COutputLogger instance that called registered the message.
-
std::string body
Actual content of the message.
-
TMsg(const mrpt::system::VerbosityLevel level, std::string_view msg, const COutputLogger &logger)