#include <logsink.h>
Detailed Description
An implementation of log sink and source.
To log the output of your Client or Component, use ClientBase's logInstance() to get hold of the LogSink object for that ClientBase. Register your LogHandler with that instance.
You should not need to use this class directly.
- Author
- Jakob Schroeter js@ca.nosp@m.maya.nosp@m..net
- Since
- 0.8
Definition at line 38 of file logsink.h.
Constructor & Destructor Documentation
Member Function Documentation
void dbg |
( |
LogArea |
area, |
|
|
const std::string & |
message |
|
) |
| const |
|
inline |
Use this function to log a debug message with given LogIdentifier. This is a convenience wrapper around log().
- Parameters
-
area | The part of the program/library the message comes from. |
message | The actual log message. |
Definition at line 66 of file logsink.h.
void err |
( |
LogArea |
area, |
|
|
const std::string & |
message |
|
) |
| const |
|
inline |
Use this function to log a error message with given LogIdentifier. This is a convenience wrapper around log().
- Parameters
-
area | The part of the program/library the message comes from. |
message | The actual log message. |
Definition at line 84 of file logsink.h.
void log |
( |
LogLevel |
level, |
|
|
LogArea |
area, |
|
|
const std::string & |
message |
|
) |
| const |
Use this function to log a message with given LogLevel and LogIdentifier. dbg(), warn(), and err() are alternative shortcuts.
- Parameters
-
level | The severity of the logged event. |
area | The part of the program/library the message comes from. |
message | The actual log message. |
Definition at line 28 of file logsink.cpp.
Registers lh
as object that receives all debug messages of the specified type. Suitable for logging to a file, etc.
- Parameters
-
level | The LogLevel for this handler. |
areas | Bit-wise ORed LogAreas the LogHandler wants to be informed about. |
lh | The object to receive exchanged data. |
Definition at line 38 of file logsink.cpp.
Removes the given object from the list of log handlers.
- Parameters
-
lh | The object to remove from the list. |
Definition at line 44 of file logsink.cpp.
void warn |
( |
LogArea |
area, |
|
|
const std::string & |
message |
|
) |
| const |
|
inline |
Use this function to log a warning message with given LogIdentifier. This is a convenience wrapper around log().
- Parameters
-
area | The part of the program/library the message comes from. |
message | The actual log message. |
Definition at line 75 of file logsink.h.
The documentation for this class was generated from the following files: