• Skip to content
  • Skip to link menu
KDE 4.4 API Reference
  • KDE API Reference
  • kdelibs
  • Sitemap
  • Contact Us
 

KDECore

KDebug Class Reference
[Debug message generators]

#include <kdebug.h>

List of all members.

Public Member Functions

 KDebug (QtMsgType type, const char *f=0, int l=-1, const char *info=0)
QDebug operator() (bool cond, int area=KDE_DEFAULT_DEBUG_AREA)
QDebug operator() (int area=KDE_DEFAULT_DEBUG_AREA)

Static Public Member Functions

static bool hasNullOutput (QtMsgType type, bool condition, int area, bool enableByDefault)
static bool hasNullOutput (QtMsgType type, bool condition, int area)
static bool hasNullOutput (QtMsgType type, int area)
static bool hasNullOutputQtDebugMsg (bool condition, int area=KDE_DEFAULT_DEBUG_AREA)
static bool hasNullOutputQtDebugMsg (int area=KDE_DEFAULT_DEBUG_AREA)
static int registerArea (const QByteArray &areaName, bool enabled=true)

Detailed Description

For internal use only.

A class for using operator()

Definition at line 234 of file kdebug.h.


Constructor & Destructor Documentation

KDebug::KDebug ( QtMsgType  type,
const char *  f = 0,
int  l = -1,
const char *  info = 0 
) [inline, explicit]

Definition at line 241 of file kdebug.h.


Member Function Documentation

bool KDebug::hasNullOutput ( QtMsgType  type,
bool  condition,
int  area,
bool  enableByDefault 
) [static]

For internal use only.

Definition at line 757 of file kdebug.cpp.

bool KDebug::hasNullOutput ( QtMsgType  type,
bool  condition,
int  area 
) [static]

For internal use only.

Definition at line 747 of file kdebug.cpp.

bool KDebug::hasNullOutput ( QtMsgType  type,
int  area 
) [static]

For internal use only.

Definition at line 741 of file kdebug.cpp.

static bool KDebug::hasNullOutputQtDebugMsg ( bool  condition,
int  area = KDE_DEFAULT_DEBUG_AREA 
) [inline, static]

For internal use only.

Definition at line 269 of file kdebug.h.

static bool KDebug::hasNullOutputQtDebugMsg ( int  area = KDE_DEFAULT_DEBUG_AREA  )  [inline, static]

For internal use only.

Definition at line 266 of file kdebug.h.

QDebug KDebug::operator() ( bool  cond,
int  area = KDE_DEFAULT_DEBUG_AREA 
) [inline]

Definition at line 247 of file kdebug.h.

QDebug KDebug::operator() ( int  area = KDE_DEFAULT_DEBUG_AREA  )  [inline]

Definition at line 245 of file kdebug.h.

int KDebug::registerArea ( const QByteArray &  areaName,
bool  enabled = true 
) [static]
Since:
4.4 Register a debug area dynamically.
Parameters:
areaName the name of the area
enabled whether debug output should be enabled by default (users can override this in kdebugdialog or with DisableAll=true in kdebugrc)
Returns:
the area code that was allocated for this area

Typical usage: If all uses of the debug area are restricted to a single class, add a method like this (e.g. into the Private class, if there's one) static int debugArea() { static int s_area = KDebug::registerArea("areaName"); return s_area; }

If all uses of the debug area are restricted to a single .cpp file, do the same but outside any class, and then use a more specific name for the function.

If however multiple classes and files need the debug area, then declare it in one file without static, and use "extern int debugArea();" in other files (with a better name for the function of course).

Definition at line 795 of file kdebug.cpp.


The documentation for this class was generated from the following files:
  • kdebug.h
  • kdebug.cpp

KDECore

Skip menu "KDECore"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUtils
  • Nepomuk
  • Plasma
  •     Sodep
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.5.9-20090814
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal