Files
pilotclient/samples/blackcore/tool.h
Klaus Basan 429f79f841 refs #199, extended core to new functionality
* enable/disable signal/slot log
* redirection of output as qDebug, qWarning, ..
2014-04-17 00:09:50 +02:00

39 lines
814 B
C++

#ifndef BLACKMISCTEST_Tool_H
#define BLACKMISCTEST_Tool_H
#include "blackcore/context_runtime.h"
#include <QCoreApplication>
#include <QProcess>
#include <QDBusConnection>
namespace BlackMiscTest
{
/*!
* \brief Supporting functions for running the tests
*/
class Tool
{
private:
//! \brief Constructor
Tool() {}
public:
//! \brief Get process id
static qint64 getPid()
{
return QCoreApplication::applicationPid();
}
//! Start a new process
static QProcess *startNewProcess(const QString &executable, const QStringList &arguments = QStringList(), QObject *parent = 0);
//! \brief Server loop
static void serverLoop(BlackCore::CRuntime *runtime);
};
} // namespace
#endif // guard