34#ifndef API_MIP_LOG_MESSAGE_DATA_H_
35#define API_MIP_LOG_MESSAGE_DATA_H_
62 const std::string& message,
63 const std::string& function,
64 const std::string& file,
66 const std::shared_ptr<void>& context,
67 std::chrono::time_point<std::chrono::system_clock> messageTime,
68 std::thread::id messageThreadId)
75 mMessageTime(messageTime),
76 mMessageThreadId(messageThreadId) {
97 const std::string&
GetFile()
const {
return mFile; }
107 const std::shared_ptr<void>&
GetContext()
const {
return mContext; }
112 std::chrono::time_point<std::chrono::system_clock>
GetMessageTime()
const {
return mMessageTime; }
121 std::string mLogMessage;
122 std::string mFunction;
125 std::shared_ptr<void> mContext;
126 std::chrono::time_point<std::chrono::system_clock> mMessageTime;
127 std::thread::id mMessageThreadId;
Base class for all errors that will be reported (thrown or returned) from MIP SDK.
A class that stores log messages.
const std::shared_ptr< void > & GetContext() const
The logger context for the log statement.
LogMessageData(const LogLevel level, const std::string &message, const std::string &function, const std::string &file, int32_t line, const std::shared_ptr< void > &context, std::chrono::time_point< std::chrono::system_clock > messageTime, std::thread::id messageThreadId)
std::chrono::time_point< std::chrono::system_clock > GetMessageTime() const
The message time of the log statement.
std::thread::id GetMessageThreadId() const
The thread id of the log statement.
const std::string & GetLogMessage() const
The message for the log statement.
const std::string & GetFile() const
The file name for the log statement.
const std::string & GetFunction() const
The function name for the log statement.
LogLevel GetLevel() const
The log level for the log statement.
int32_t GetLine() const
The line number for the log statement.
LogLevel
Different log levels used across the MIP SDK.