You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
588 B

#ifndef CSCI_SIMULATION_TASK_H
#define CSCI_SIMULATION_TASK_H
#include <QObject>
#include <QtConcurrent>
class SimulationTask:public QObject {
Q_OBJECT
private:
QHash<QString, QVariant> _state;
public:
SimulationTask();
SimulationTask(const SimulationTask &task);
public:
void setSate(const QString& key, const QVariant& state);
public:
// TODO 具体模型需要实现的计算
static void compute(QHash<QString, QVariant> state);
public:signals:
void feather(QVariant state);
public slots:
void run();
};
#endif //CSCI_SIMULATION_TASK_H