17#include "loggingtypes.h"
18#include <Kanoop/kanoopcommon.h>
45 _level(DefaultLogLevel) {}
51 QString
name()
const {
return _name; }
96 bool isValid()
const {
return _name.length() != 0; }
A named logging category with an associated minimum log level.
LogCategory()
Default constructor — creates an invalid (unnamed) category at the default level.
QString _name
Category name string.
QString name() const
Return the category name.
LogCategory(const QString &name)
Construct a named category at the default log level.
static void setDefaultLogLevel(LogLevel value)
Set the process-wide default log level used for new categories.
LogLevel level() const
Return the minimum log level for this category.
LogCategory append(const QString &name)
Create a new category by appending a sub-name to this category's name.
static LogLevel defaultLogLevel()
Return the process-wide default log level used for new categories.
LogLevel _level
Minimum log level threshold for this category.
static QString parentName(const QString &name)
Extract the parent portion of a dotted category name.
bool isValid() const
Test whether this category has a non-empty name.
LogCategory prepend(const QString &name)
Create a new category by prepending a prefix to this category's name.
static LogLevel DefaultLogLevel
Process-wide default log level applied to newly created categories.
Logging subsystem providing categorized, level-filtered output.
LogLevel
Severity levels for log messages, ordered from most to least critical.