DebugEnabler Class Reference
A holder for a debug level.
More...
#include <yateclass.h>
List of all members.
Detailed Description
A holder for a debug level.
Holds a local debugging level that can be modified separately from the global debugging
Constructor & Destructor Documentation
DebugEnabler |
( |
int |
level = TelEngine::debugLevel() , |
|
|
bool |
enabled = true | |
|
) |
| | [inline] |
Constructor
- Parameters:
-
| level | The initial local debug level |
| enabled | Enable debugging on this object |
References TelEngine::debugLevel().
Member Function Documentation
int debugLevel |
( |
|
) |
const [inline] |
Retrive the current local debug level
- Returns:
- The current local debug level
int debugLevel |
( |
int |
level |
) |
|
Set the current local debug level.
- Parameters:
-
| level | The desired debug level |
- Returns:
- The new debug level (may be different)
bool debugEnabled |
( |
|
) |
const [inline] |
Retrive the current debug activation status
- Returns:
- True if local debugging is enabled
void debugEnabled |
( |
bool |
enable |
) |
[inline] |
Set the current debug activation status
- Parameters:
-
| enable | The new debug activation status, true to enable |
const char* debugName |
( |
|
) |
const [inline] |
Get the current debug name
- Returns:
- Name of the debug activation if set or NULL
bool debugAt |
( |
int |
level |
) |
const |
Check if debugging output should be generated
- Parameters:
-
| level | The debug level we are testing |
- Returns:
- True if messages should be output, false otherwise
bool debugChained |
( |
|
) |
const [inline] |
Check if this enabler is chained to another one
- Returns:
- True if local debugging is chained to other enabler
Chain this debug holder to a parent or detach from existing one
- Parameters:
-
| chain | Pointer to parent debug level, NULL to detach |
Copy debug settings from another object or from engine globals
- Parameters:
-
void debugName |
( |
const char * |
name |
) |
[inline, protected] |
Set the current debug name
- Parameters:
-
| name | Static debug name or NULL |
The documentation for this class was generated from the following file: