cutter/src/common/R2Task.h

33 lines
521 B
C
Raw Normal View History

2018-07-22 13:04:13 +00:00
#ifndef R2TASK_H
#define R2TASK_H
#include "core/Cutter.h"
2018-07-22 13:04:13 +00:00
class R2Task: public QObject
{
Q_OBJECT
private:
RCoreTask *task;
static void taskFinishedCallback(void *user, char *);
void taskFinished();
public:
2018-11-11 09:40:42 +00:00
explicit R2Task(const QString &cmd, bool transient = true);
2018-07-22 13:04:13 +00:00
~R2Task();
void startTask();
void breakTask();
void joinTask();
QString getResult();
QJsonDocument getResultJson();
2018-07-22 13:04:13 +00:00
const char *getResultRaw();
signals:
void finished();
};
#endif // R2TASK_H