refs #786, prepare contexts for matching messages

In same step cleaned up contexts a bit
* added function for model set strings
* renamed functions to getModelSet... instead of installed models (the set is smaller and is what we want to use with DBus)
* signal when debug/log flags changed
* removed some \copydoc
* allow to enable/disable rev.lookup/matching messages
* removed reload model function (dangling)
This commit is contained in:
Klaus Basan
2016-10-23 03:04:31 +02:00
parent 1e3afea9c2
commit c2bf473f3f
15 changed files with 226 additions and 202 deletions

View File

@@ -38,6 +38,8 @@ namespace BlackCore
//! Base for all context classes
class BLACKCORE_EXPORT CContext : public QObject
{
Q_OBJECT
public:
//! Destructor
virtual ~CContext() {}
@@ -83,9 +85,9 @@ namespace BlackCore
//! Unique id
qint64 getUniqueId() const { return this->m_contextId; }
//
// ---------------------------------------------------------------
// cross context access
//
// ---------------------------------------------------------------
//! Context for application
const IContextApplication *getIContextApplication() const;
@@ -126,6 +128,10 @@ namespace BlackCore
//! Id and path name for round trip protection
virtual QString getPathAndContextId() const = 0;
signals:
//! Log or debug values changed
void changedLogOrDebugSettings();
protected:
CCoreFacadeConfig::ContextMode m_mode; //!< How context is used
qint64 m_contextId; //!< unique identifer, avoid redirection rountrips
@@ -142,6 +148,9 @@ namespace BlackCore
return QString(path) + ":" + QString::number(this->getUniqueId());
}
//! Relay signals from this class
void relayBaseClassSignals(const QString &serviceName, QDBusConnection &connection, const QString &objectPath, const QString &interfaceName);
//! Empty context called
void logEmptyContextWarning(const QString &functionName) const
{