refs #576, logging

* log category
* fixed join for status message
This commit is contained in:
Klaus Basan
2016-01-23 02:18:56 +01:00
parent de4b07dc32
commit 394edc67a0
3 changed files with 10 additions and 1 deletions

View File

@@ -85,6 +85,13 @@ namespace BlackMisc
return cat;
}
//! Mapping
static const CLogCategory &mapping()
{
static const CLogCategory cat { "swift.mapping" };
return cat;
}
//! Webservice with swift DB
static const CLogCategory &swiftDbWebservice()
{
@@ -105,6 +112,7 @@ namespace BlackMisc
guiComponent(),
download(),
webservice(),
mapping(),
swiftDbWebservice(),
};
return cats;

View File

@@ -19,6 +19,7 @@ namespace BlackMisc
{ "uncategorized (swift)", exactMatch(CLogCategory::uncategorized()) },
{ "validation", exactMatch(CLogCategory::validation()) },
{ "verification", exactMatch(CLogCategory::verification()) },
{ "model mapping", exactMatch(CLogCategory::mapping()) },
{ "swift contexts", exactMatch(CLogCategory::context()) },
{ "swift context slots", exactMatch(CLogCategory::contextSlot()) },
{ "swift GUI", exactMatch(CLogCategory::guiComponent()) },

View File

@@ -115,7 +115,7 @@ namespace BlackMisc
newMsgs.append(msg.getMessage());
CStatusMessage::StatusSeverity ms = msg.getSeverity();
if (s < ms) { s = ms; }
cats.join(msg.getCategories());
cats = cats.join(msg.getCategories());
}
const CStatusMessage newMsg(cats, s, newMsgs.join(", "));
return newMsg;