16 #include "Device/Histo/SimulationResult.h"
17 #include "Sim/Simulation/ScatteringSimulation.h"
23 : m_identifier(std::move(identifier))
24 , m_simulation(simulation)
25 , m_percentage_done(0)
27 , m_terminate_request_flag(false)
63 }
catch (
const std::exception& ex) {
67 "JobRunner::start() -> ISimulation failed with exception throw:\n\n";
JobStatus
The JobStatus enum lists the possible states of a job.
@ Completed
the job was successfully completed
@ Canceled
the job was stopped by the user
@ Running
the job is busy calculating
@ Failed
the job aborted because it hit an error
@ Idle
the job has not been started yet
bool updateProgress(int percentage_done)
Sets current progress. Returns true if we want to continue the simulation.
QDateTime m_simulation_end
const QDateTime & simulationStart() const
QString failureMessage() const
QString identifier() const
bool m_terminate_request_flag
const SimulationResult * result() const
QDateTime m_simulation_start
JobWorker(QString identifier, ISimulation *simulation)
std::unique_ptr< const SimulationResult > m_result
const QDateTime & simulationEnd() const
QString m_failure_message
void terminate()
Sets request for JobRunner to terminate underlying domain simulation.
ISimulation * m_simulation