refs #250, helper methods

* in aircraft class to compare COM
* in context / runtime component to check vitality of core
This commit is contained in:
Klaus Basan
2014-05-22 12:15:01 +02:00
parent 23b1013be7
commit e0b06e1555
5 changed files with 36 additions and 0 deletions

View File

@@ -398,6 +398,20 @@ namespace BlackCore
m_init = true;
}
bool CRuntime::hasRemoteApplicationContext() const
{
Q_ASSERT(this->m_contextApplication);
return !this->m_contextApplication->usingLocalObjects();
}
bool CRuntime::canPingApplicationContext() const
{
Q_ASSERT(this->m_contextApplication);
if (this->m_contextApplication->usingLocalObjects()) return true;
qint64 token = QDateTime::currentMSecsSinceEpoch();
return (token == this->m_contextApplication->ping(token));
}
void CRuntime::initDBusServer(const QString &dBusAddress)
{
if (this->m_dbusServer) return;