refs #614, categories

This commit is contained in:
Klaus Basan
2016-04-08 13:06:33 +02:00
parent 32ce813bab
commit 5254d0ff71
2 changed files with 22 additions and 12 deletions

View File

@@ -113,6 +113,13 @@ namespace BlackMisc
return cat;
}
//! VATSIM specific
static const CLogCategory &vatsimSpecific()
{
static const CLogCategory cat { "swift.vatsim" };
return cat;
}
//! All predefined special categories
//! \note Human readable patterns are defined in CLogPattern::allHumanReadablePatterns
static const QList<CLogCategory> &allSpecialCategories()
@@ -129,6 +136,7 @@ namespace BlackMisc
swiftDbWebservice(),
services(),
validation(),
vatsimSpecific(),
verification(),
webservice()
};

View File

@@ -16,19 +16,21 @@ namespace BlackMisc
{
static const QHash<QString, CLogPattern> patterns
{
{ "uncategorized (swift)", exactMatch(CLogCategory::uncategorized()) },
{ "validation", exactMatch(CLogCategory::validation()) },
{ "verification", exactMatch(CLogCategory::verification()) },
{ "services", exactMatch(CLogCategory::services()) },
{ "model mapping", exactMatch(CLogCategory::mapping()) },
{ "swift contexts", exactMatch(CLogCategory::context()) },
{ "swift context slots", exactMatch(CLogCategory::contextSlot()) },
{ "swift GUI", exactMatch(CLogCategory::guiComponent()) },
{ "downloading data", exactMatch(CLogCategory::download()) },
{ "webservice related", exactMatch(CLogCategory::webservice()) },
{ "uncategorized (swift)", exactMatch(CLogCategory::uncategorized()) },
{ "validation", exactMatch(CLogCategory::validation()) },
{ "verification", exactMatch(CLogCategory::verification()) },
{ "services", exactMatch(CLogCategory::services()) },
{ "model mapping", exactMatch(CLogCategory::mapping()) },
{ "model matching", exactMatch(CLogCategory::matching()) },
{ "swift contexts", exactMatch(CLogCategory::context()) },
{ "swift context slots", exactMatch(CLogCategory::contextSlot()) },
{ "swift GUI", exactMatch(CLogCategory::guiComponent()) },
{ "downloading data", exactMatch(CLogCategory::download()) },
{ "VASTIM specific", exactMatch(CLogCategory::vatsimSpecific()) },
{ "webservice related", exactMatch(CLogCategory::webservice()) },
{ "swift DB webservice related", exactMatch(CLogCategory::swiftDbWebservice()) },
{ "Qt library", startsWith("qt.") },
{ "uncategorized (other)", empty() }
{ "Qt library", startsWith("qt.") },
{ "uncategorized (other)", empty() }
};
return patterns;
}