12 #include <vlutil/vlPrint.h>
13 #include <vlutil/vlExceptions.h>
18 #define DT_LOG_FATAL log().out(makVrv::DtDebugLog::Fatal) << "Fatal: " << __FUNCTION__ << ": "
19 #define DT_LOG_WARN log().out(makVrv::DtDebugLog::Warning) << "Warning: " << __FUNCTION__ << ": "
20 #define DT_LOG_INFO log().out(makVrv::DtDebugLog::Information) << "Info: " << __FUNCTION__ << ": "
21 #define DT_LOG_DEBUG log().out(makVrv::DtDebugLog::Debug) << "Debug: " << __FUNCTION__ << ": "
22 #define DT_LOG_OUT log().out()
23 #define DT_LOG_LEVEL(a) log().levelWillPrint(a)
54 DtDebugLog(
const std::string& filepath,
bool attachGlobalLogStreams=
true);
63 return level() >= alevel;
70 virtual void setOutputStream(DtOutputStream*
stream);
78 if(levelWillPrint(
level))
81 return *myEmptyOutput;
85 DtOutputStream* outputStream();
#define DT_DLL_VRVUTIL
Definition: vrvUtil.h:34
bool levelWillPrint(DtDebugLog::PrintLevel alevel)
Check to see if the provided level would print with the current level.
Definition: DtDebugLog.h:61
std::ostream & out(DtDebugLog::PrintLevel level=DtDebugLog::Information)
Get the log output.
Definition: DtDebugLog.h:76
DT_DLL_VRVCORE DtTaitBryan level(const DtCoordinateSystem &cs, const DtVector &localOrigin, double topoHeading)
Returns a level orientation with the topographic heading.
This is a simple class for logging information to a file. To be used, the caller must specify a loggi...
Definition: DtDebugLog.h:38
PrintLevel
Definition: DtDebugLog.h:42
Contains DLL export macros.
DtFilePrinter * myFilePrinter
The file printer to log to.
Definition: DtDebugLog.h:93
DtOutputStream * myOutput
The output stream that does all the work. When the stream is created, its threshold is set to myPrint...
Definition: DtDebugLog.h:110
Definition: DtDebugLog.h:46
DtOutputStreamBuffer * myBuffer
The buffer used by the output stream.
Definition: DtDebugLog.h:96
std::ostream * myEmptyOutput
The 'black hole' output stream When the stream is created, its threshold is set to myPrintLevelThresh...
Definition: DtDebugLog.h:115
voidpf stream
Definition: ioapi.h:39
PrintLevel myLevel
variable used to decide whether send output to the 'works always' stream (myOutput) or the 'works ne...
Definition: DtDebugLog.h:90
DtOutputStreamBuffer * myEmptyBuffer
The buffer used by the empty output stream.
Definition: DtDebugLog.h:99
int myPrintLevelThresholdRef
The dummy 'global notify level' that our DtOutputStream's will compare their configured thresholds to...
Definition: DtDebugLog.h:105