Medical Imaging Interaction Toolkit  2018.4.99-65942676
Medical Imaging Interaction Toolkit
mbilogLogMessage.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 _mbilogLogMessage_H
14 #define _mbilogLogMessage_H
15 
16 #include <string>
17 
18 #include "mbilogExports.h"
19 
20 namespace mbilog
21 {
29  // todo convert to Struct
31  {
32  public:
33  // TODO: all member names m_[...]
34 
36  const int level;
37 
38  // the data of the following section is generated by the c-compiler
39 
42  const char *filePath;
45  const int lineNumber;
48  const char *functionName;
49 
50  // the data of the following section is generated by the mitk module system
51 
54  const char *moduleName;
55 
56  // user parameters
57 
59  std::string category;
60 
62  std::string message;
63 
64  LogMessage(const int _level, const char *_filePath, const int _lineNumber, const char *_functionName)
65  : level(_level), filePath(_filePath), lineNumber(_lineNumber), functionName(_functionName)
66  {
67  }
68  };
69 }
70 
71 #endif
const char * moduleName
Name of the module where the logging message was emitted which is generated by the macros in file mbi...
#define MBILOG_EXPORT
Definition: mbilogExports.h:15
const char * filePath
File name of the source file where the logging message was emitted which is generated by the macros i...
std::string message
The actual logging message.
An object of this class represents a single logging message (logging event) of the mbi logging mechan...
LogMessage(const int _level, const char *_filePath, const int _lineNumber, const char *_functionName)
const int lineNumber
Line of the source source file where the logging message was emitted which is generated by the macros...
const char * functionName
Name of the method where the logging message was emitted which is generated by the macros in file mbi...
std::string category
Category of the logging event, which was defined by the user.
const int level
Logging level which is defined in the enum mbilogLoggingTypes.h TODO: convert to enum.
Definition: mbilog.h:25