#include <Logger.h>
Definition at line 145 of file Logger.h.
Public Member Functions | |
short | Printf (const char *source, long lineNumber, int type, const char *format,...) |
Writes a log message into the log file. | |
~Logger () | |
Destroys the logger. | |
Static Public Member Functions | |
Logger * | Get () |
Returns the logger singleton. | |
Private Member Functions | |
void | Close () |
Closes the log file, if it is open. | |
Logger () | |
Creates a new logger. | |
bool | Open () |
Opens the log file, if it is not already open. | |
void | WriteTimeStampPrefix () |
Writes the date/time prefix. | |
void | WriteTimeStampPrefix (int type) |
Writes the date/time and type prefix. | |
Private Attributes | |
FILE * | File |
The log file. | |
char * | FileName |
The log file name. | |
int | LogLevel |
The current log level (logging threshold). | |
bool | OptionSet |
Whether a command line option for the log level is set. | |
unsigned long | StartTickCount |
The tick count on logger startup. | |
Static Private Attributes | |
Logger | Singleton |
The logger singleton. |
|
Creates a new logger.
|
|
Destroys the logger.
|
|
Closes the log file, if it is open.
|
|
Returns the logger singleton.
|
|
Opens the log file, if it is not already open.
|
|
Writes a log message into the log file. Source name and line number are also added automatically. Another feature of this method is the ellipse to provide flexibility like the printf functions of C. Do not call this method directly, but use the LOGPRINTFx macros, that automatically add source name and line number.
|
|
Writes the date/time prefix.
|
|
Writes the date/time and type prefix.
|
|
The log file.
|
|
The log file name.
|
|
The current log level (logging threshold).
|
|
Whether a command line option for the log level is set.
|
|
The logger singleton.
|
|
The tick count on logger startup.
|