#ifndef OJPROBLEMCASESRUNNER_H #define OJPROBLEMCASESRUNNER_H #include "runner.h" #include #include "../problems/ojproblemset.h" class OJProblemCasesRunner : public Runner { Q_OBJECT public: explicit OJProblemCasesRunner(const QString& filename, const QString& arguments, const QString& workDir, const QVector& problemCases, QObject *parent = nullptr); explicit OJProblemCasesRunner(const QString& filename, const QString& arguments, const QString& workDir, POJProblemCase problemCase, QObject *parent = nullptr); signals: void caseStarted(const QString& id, int total, int current); void caseFinished(const QString& id, int total, int current); private: void runCase(int index, POJProblemCase problemCase); private: QVector mProblemCases; // QThread interface protected: void run() override; }; #endif // OJPROBLEMCASESRUNNER_H