Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitkLogMessage.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef mitkLogMessage_h
14 #define mitkLogMessage_h
15 
16 #include <mitkLogLevel.h>
17 
18 #include <string>
19 
20 #include <MitkLogExports.h>
21 
22 namespace mitk
23 {
37  {
38  public:
46  LogMessage(const LogLevel level, const std::string& filePath, const int lineNumber, const std::string& functionName);
47 
52  const LogLevel Level;
53 
58  const std::string FilePath;
59 
64  const int LineNumber;
65 
70  const std::string FunctionName;
71 
77  std::string ModuleName;
78 
84  std::string Category;
85 
91  std::string Message;
92  };
93 }
94 
95 #endif
#define MITKLOG_EXPORT
Find image slices visible on a given plane.
LogLevel
Severity levels for log messages in the MITK log mechanism.
Definition: mitkLogLevel.h:27
A single log message (log event) of the MITK log mechanism.
const LogLevel Level
Severity level of the log message.
const std::string FunctionName
Name of the function or method where the log message was emitted.
std::string ModuleName
Name of the MITK module where the log message was emitted.
std::string Category
Optional user-defined category for the log event.
const std::string FilePath
Absolute or relative path of the source file where the log message was emitted.
std::string Message
The actual log message text.
LogMessage(const LogLevel level, const std::string &filePath, const int lineNumber, const std::string &functionName)
Construct a log message with source location information.
const int LineNumber
Line number in the source file where the log message was emitted.