|
Computer Assited Medical Intervention Tool Kit
version 5.0
|
|
Go to the documentation of this file.
26 #ifndef CAMITKLOGGER_H
27 #define CAMITKLOGGER_H
138 void setLogLevel(
LogLevel level)
override;
142 void setLogToStandardOutput(
bool writeToStdOut)
override;
147 bool getLogToStandardOutput()
override;
156 bool setLogToFile(
bool writeToFile)
override;
174 bool setLogFileDirectory(QDir directoryName,
bool moveExistingLogFile =
true)
override;
177 bool getLogToFile()
override;
180 QFileInfo getLogFileInfo()
override;
187 void setMessageBoxLevel(
LogLevel level)
override;
190 LogLevel getMessageBoxLevel()
override;
196 void setDebugInformation(
bool)
override;
199 bool getDebugInformation()
override;
206 void setTimeStampInformation(
bool showTimeStamp)
override;
209 bool getTimeStampInformation()
override;
222 QString log(
const QString msg,
const LogLevel level,
char const* fileName,
char const* methodName,
int lineNumber,
const QObject* sender =
nullptr)
override final;
227 virtual QString buildLogMessage(QString message,
LogLevel level,
char const* fileName,
char const* methodName,
int lineNumber,
const QObject* sender =
nullptr);
231 QString getCamiTKAPIInformation(
const QObject* sender);
234 bool openLogFile(
bool moveFile =
false, QFileInfo fileToMove = QFileInfo());
273 #endif // CAMITKLOGGER_H
CamiTKLogger()
Default constructor.
Definition: CamiTKLogger.cpp:72
QFile * logFile
Current log file (the stream is flushed log message by log message)
Definition: CamiTKLogger.h:261
QString getName() const
Get the main window title.
Definition: MainWindow.cpp:218
bool logToStdOut
is the logger currently writing everything to the standard output
Definition: CamiTKLogger.h:246
bool displayDebugInformation
display debug information (file/class name, method name and line number)
Definition: CamiTKLogger.h:252
QDir logFileDirectory
Current directory for the log file.
Definition: CamiTKLogger.h:258
This class describes what is a generic Component extension. To add a ComponentExtension to CamiTK cor...
Definition: ComponentExtension.h:83
QString getName() const
get the name of the action
Definition: Action.h:338
bool logToFile
is the logger currently writing everything to a file
Definition: CamiTKLogger.h:249
This is the default logger for CamiTK.
Definition: CamiTKLogger.h:123
Action class is an abstract class that enables you to build a action (generally on a component)....
Definition: Action.h:231
virtual QString getName()=0
returns the viewer extension name (to be overriden in the derived class)
InterfaceLogger::LogLevel level
current log level
Definition: CamiTKLogger.h:240
The generic/default application. Once this class is intanciated in the main, everything is setup....
Definition: Application.h:82
InterfaceLogger::LogLevel messageBoxLevel
current level for message boxes
Definition: CamiTKLogger.h:243
QTextStream * logStream
Current stream to output to the log file.
Definition: CamiTKLogger.h:264
QString getName() const override
get the name to be displayed
Definition: sdk/libraries/core/component/Component.h:907
LogLevel
Definition: InterfaceLogger.h:60
QDateTime logStartTime
instantiation time
Definition: CamiTKLogger.h:267
bool displayTimeStampInformation
display time stamp information (in the form "yyyy-MM-dd HH:mm:ss.zzz")
Definition: CamiTKLogger.h:255
static QString getName()
get the application name
Definition: Application.cpp:203
This class is the base class for your application. It sets up the main window and creates a menubar,...
Definition: MainWindow.h:89
This class describes what is a generic Action extension. To add a ActionExtension to CamiTK core,...
Definition: ActionExtension.h:80
Viewer is an abstract class that is the base class for all viewers.
Definition: Viewer.h:180
This class describes what is a generic Action extension. To add a ActionExtension to CamiTK core,...
Definition: ViewerExtension.h:108
virtual QString getName()=0
returns the action extension name (to be overriden in your ActionExtension)
virtual QString getName() const =0
The CamiTK logger interface provides a flexible tracing system to CamiTK applications....
Definition: InterfaceLogger.h:51
A Component represents something that could be included in the explorer view, the interactive 3D view...
Definition: sdk/libraries/core/component/Component.h:302
#define CAMITK_API
Definition: CamiTKAPI.h:49
Definition: Action.cpp:35