Medical Imaging Interaction Toolkit  2024.12.99-0da743f6
Medical Imaging Interaction Toolkit
QmitkDataGenerationJobBase Class Referenceabstract

QmitkDataGenerationJobBase Base class for generation jobs used by QmitkDataGenerationBase and derived classes. More...

#include <QmitkDataGenerationJobBase.h>

Inheritance diagram for QmitkDataGenerationJobBase:
Collaboration diagram for QmitkDataGenerationJobBase:

Public Types

using ResultMapType = std::map< std::string, mitk::BaseData::Pointer >
 

Signals

void Error (QString err, const QmitkDataGenerationJobBase *job)
 
void ResultsAvailable (ResultMapType results, const QmitkDataGenerationJobBase *job)
 Signal is emitted when results are available. More...
 

Public Member Functions

virtual ResultMapType GetResults () const =0
 
void run () final
 
bool GetComputationSuccessFlag () const
 
std::string GetLastErrorMessage () const
 
bool IsRunning () const
 

Protected Member Functions

 QmitkDataGenerationJobBase ()=default
 
virtual ~QmitkDataGenerationJobBase ()=default
 
virtual bool RunComputation ()=0
 

Protected Attributes

std::string m_LastErrorMessage
 

Detailed Description

QmitkDataGenerationJobBase Base class for generation jobs used by QmitkDataGenerationBase and derived classes.

Definition at line 32 of file QmitkDataGenerationJobBase.h.

Member Typedef Documentation

◆ ResultMapType

Result map that indicates all results generated by the job. The key is a job specific label for the results.

Definition at line 39 of file QmitkDataGenerationJobBase.h.

Constructor & Destructor Documentation

◆ QmitkDataGenerationJobBase()

QmitkDataGenerationJobBase::QmitkDataGenerationJobBase ( )
protecteddefault

◆ ~QmitkDataGenerationJobBase()

virtual QmitkDataGenerationJobBase::~QmitkDataGenerationJobBase ( )
protectedvirtualdefault

Member Function Documentation

◆ Error

void QmitkDataGenerationJobBase::Error ( QString  err,
const QmitkDataGenerationJobBase job 
)
signal

◆ GetComputationSuccessFlag()

bool QmitkDataGenerationJobBase::GetComputationSuccessFlag ( ) const

/brief Returns a flag the indicates if the job computation was successful.

◆ GetLastErrorMessage()

std::string QmitkDataGenerationJobBase::GetLastErrorMessage ( ) const

◆ GetResults()

virtual ResultMapType QmitkDataGenerationJobBase::GetResults ( ) const
pure virtual

◆ IsRunning()

bool QmitkDataGenerationJobBase::IsRunning ( ) const

◆ ResultsAvailable

void QmitkDataGenerationJobBase::ResultsAvailable ( ResultMapType  results,
const QmitkDataGenerationJobBase job 
)
signal

Signal is emitted when results are available.

Parameters
resultsproduced by the job and ready to be used.
jobthe job that produced the data

◆ run()

void QmitkDataGenerationJobBase::run ( )
final

Calls RunComputation() and takes care of the error handling and result signalling.

◆ RunComputation()

virtual bool QmitkDataGenerationJobBase::RunComputation ( )
protectedpure virtual

Does the real computation. Returns true if there where results produced.

Implemented in QmitkImageStatisticsCalculationRunnable.

Member Data Documentation

◆ m_LastErrorMessage

std::string QmitkDataGenerationJobBase::m_LastErrorMessage
protected

Definition at line 70 of file QmitkDataGenerationJobBase.h.


The documentation for this class was generated from the following file: