Home · All Classes · All Namespaces · Modules · Functions · Files
Typedefs | Functions
Common debug support

Typedefs

Functions


Detailed Description

TelepathyQt4 has an internal mechanism for displaying debugging output. It uses the Qt4 debugging subsystem, so if you want to redirect the messages, use qInstallMsgHandler() from <QtGlobal>.

Debugging output is divided into two categories: normal debug output and warning messages. Normal debug output results in the normal operation of the library, warning messages are output only when something goes wrong. Each category can be invidually enabled.


Typedef Documentation

 typedef QDebug (*DebugCallback)(const QString &libraryName,
                                 const QString &libraryVersion,
                                 QtMsgType type,
                                 const QString &msg)

Function Documentation

void Tp::enableDebug ( bool  enable)

Enable or disable normal debug output from the library. If the library is not compiled with debug support enabled, this has no effect; no output is produced in any case.

The default is false ie. no debug output.

Parameters:
enableWhether debug output should be enabled or not.
void Tp::enableWarnings ( bool  enable)

Enable or disable warning output from the library. If the library is not compiled with debug support enabled, this has no effect; no output is produced in any case.

The default is true ie. warning output enabled.

Parameters:
enableWhether warnings should be enabled or not.
void Tp::setDebugCallback ( DebugCallback  cb)

Set the callback method that will handle the debug output.

If cb is NULL this method will set the defaultDebugCallback instead. The default callback function will print the output using default Qt debug system.

Parameters:
cbA function pointer to the callback method or NULL.
See also:
DebugCallback


Copyright © 2008-2011 Collabora Ltd. and Nokia Corporation
Telepathy-Qt4 0.8.0