Medical Imaging Interaction Toolkit  2022.04.99-2e1e005b
Medical Imaging Interaction Toolkit
QmitkImageAndRoiDataGeneratorBase Class Reference

#include <QmitkImageAndRoiDataGeneratorBase.h>

Inheritance diagram for QmitkImageAndRoiDataGeneratorBase:
Collaboration diagram for QmitkImageAndRoiDataGeneratorBase:

Public Types

using Superclass = QmitkDataGeneratorBase
 
using ConstNodeVectorType = std::vector< mitk::DataNode::ConstPointer >
 
using NodeVectorType = std::vector< mitk::DataNode::Pointer >
 
- Public Types inherited from QmitkDataGeneratorBase
using JobResultMapType = QmitkDataGenerationJobBase::ResultMapType
 

Public Slots

void SetImageNodes (const ConstNodeVectorType &imageNodes)
 Setter for image nodes. More...
 
void SetImageNodes (const NodeVectorType &imageNodes)
 
void SetROINodes (const ConstNodeVectorType &roiNodes)
 Setter for roi nodes. More...
 
void SetROINodes (const NodeVectorType &roiNodes)
 
- Public Slots inherited from QmitkDataGeneratorBase
void SetDataStorage (mitk::DataStorage *storage)
 
void SetAutoUpdate (bool autoUpdate)
 

Public Member Functions

ConstNodeVectorType GetImageNodes () const
 
ConstNodeVectorType GetROINodes () const
 
- Public Member Functions inherited from QmitkDataGeneratorBase
 QmitkDataGeneratorBase (const QmitkDataGeneratorBase &other)=delete
 
QmitkDataGeneratorBaseoperator= (const QmitkDataGeneratorBase &other)=delete
 
virtual ~QmitkDataGeneratorBase ()
 
mitk::DataStorage::Pointer GetDataStorage () const
 
bool GetAutoUpdate () const
 
bool IsGenerating () const
 
bool Generate () const
 
virtual bool IsValidResultAvailable (const mitk::DataNode *imageNode, const mitk::DataNode *roiNode) const =0
 

Protected Types

using InputPairVectorType = Superclass::InputPairVectorType
 
- Protected Types inherited from QmitkDataGeneratorBase
using InputPairVectorType = std::vector< std::pair< mitk::DataNode::ConstPointer, mitk::DataNode::ConstPointer > >
 

Protected Member Functions

 QmitkImageAndRoiDataGeneratorBase (mitk::DataStorage::Pointer storage, QObject *parent=nullptr)
 
 QmitkImageAndRoiDataGeneratorBase (QObject *parent=nullptr)
 
bool ChangedNodeIsRelevant (const mitk::DataNode *changedNode) const override
 
InputPairVectorType GetAllImageROICombinations () const override
 
 QmitkImageAndRoiDataGeneratorBase (const QmitkImageAndRoiDataGeneratorBase &)=delete
 
QmitkImageAndRoiDataGeneratorBaseoperator= (const QmitkImageAndRoiDataGeneratorBase &)=delete
 
- Protected Member Functions inherited from QmitkDataGeneratorBase
 QmitkDataGeneratorBase (mitk::DataStorage::Pointer storage, QObject *parent=nullptr)
 Constructor. More...
 
 QmitkDataGeneratorBase (QObject *parent=nullptr)
 
virtual void IndicateFutureResults (const mitk::DataNode *imageNode, const mitk::DataNode *roiNode) const =0
 
virtual std::pair< QmitkDataGenerationJobBase *, mitk::DataNode::PointerGetNextMissingGenerationJob (const mitk::DataNode *imageNode, const mitk::DataNode *roiNode) const =0
 Is called to generate the next job instance that needs to be done and is associated dummy node in order to progress the data generation workflow. More...
 
virtual void RemoveObsoleteDataNodes (const mitk::DataNode *imageNode, const mitk::DataNode *roiNode) const =0
 
virtual mitk::DataNode::Pointer PrepareResultForStorage (const std::string &label, mitk::BaseData *result, const QmitkDataGenerationJobBase *job) const =0
 
InputPairVectorType FilterImageROICombinations (InputPairVectorType &&imageROICombinations) const
 
std::string GetPairDescription (const InputPairVectorType::value_type &imageAndSeg) const
 
bool DoGenerate () const
 
void EnsureRecheckingAndGeneration () const
 

Protected Attributes

ConstNodeVectorType m_ImageNodes
 
ConstNodeVectorType m_ROINodes
 
- Protected Attributes inherited from QmitkDataGeneratorBase
mitk::WeakPointer< mitk::DataStoragem_Storage
 
bool m_AutoUpdate
 
std::mutex m_DataMutex
 

Additional Inherited Members

- Signals inherited from QmitkDataGeneratorBase
void DataGenerationStarted (const mitk::DataNode *imageNode, const mitk::DataNode *roiNode, const QmitkDataGenerationJobBase *job) const
 Signal that is emitted if a data generation job is started to generat outdated/inexistant data. More...
 
void NewDataAvailable (mitk::DataStorage::SetOfObjects::ConstPointer data) const
 Signal that is emitted if new final data is produced. More...
 
void GenerationFinished () const
 Signal that is emitted if all jobs are finished and everything is up to date. More...
 
void JobError (QString error, const QmitkDataGenerationJobBase *failedJob) const
 Signal that is emitted in case of job errors. More...
 
- Protected Slots inherited from QmitkDataGeneratorBase
void OnJobError (QString error, const QmitkDataGenerationJobBase *failedJob) const
 
void OnFinalResultsAvailable (JobResultMapType results, const QmitkDataGenerationJobBase *job) const
 
- Static Protected Member Functions inherited from QmitkDataGeneratorBase
static mitk::DataNode::Pointer CreateWIPDataNode (mitk::BaseData *dataDummy, const std::string &nodeName)
 

Detailed Description

Base class that can be used for generators that should alow the image nodes and the ROI nodes as vectors (like generated by node selection widgets). This class ensures that data for every combination of images and ROIs (basicly a folding) will be processed.

See also
QmitkDataGeneratorBase

Definition at line 24 of file QmitkImageAndRoiDataGeneratorBase.h.

Member Typedef Documentation

◆ ConstNodeVectorType

◆ InputPairVectorType

◆ NodeVectorType

◆ Superclass

Constructor & Destructor Documentation

◆ QmitkImageAndRoiDataGeneratorBase() [1/3]

QmitkImageAndRoiDataGeneratorBase::QmitkImageAndRoiDataGeneratorBase ( mitk::DataStorage::Pointer  storage,
QObject *  parent = nullptr 
)
inlineprotected

Definition at line 50 of file QmitkImageAndRoiDataGeneratorBase.h.

◆ QmitkImageAndRoiDataGeneratorBase() [2/3]

QmitkImageAndRoiDataGeneratorBase::QmitkImageAndRoiDataGeneratorBase ( QObject *  parent = nullptr)
inlineprotected

Definition at line 51 of file QmitkImageAndRoiDataGeneratorBase.h.

◆ QmitkImageAndRoiDataGeneratorBase() [3/3]

QmitkImageAndRoiDataGeneratorBase::QmitkImageAndRoiDataGeneratorBase ( const QmitkImageAndRoiDataGeneratorBase )
protecteddelete

Member Function Documentation

◆ ChangedNodeIsRelevant()

bool QmitkImageAndRoiDataGeneratorBase::ChangedNodeIsRelevant ( const mitk::DataNode changedNode) const
overrideprotectedvirtual

This method must be implemented by derived to indicate if a changed node is relevant and therefore if an update must be triggered.

Implements QmitkDataGeneratorBase.

Reimplemented in QmitkImageStatisticsDataGenerator.

Referenced by QmitkImageStatisticsDataGenerator::QmitkImageStatisticsDataGenerator().

◆ GetAllImageROICombinations()

InputPairVectorType QmitkImageAndRoiDataGeneratorBase::GetAllImageROICombinations ( ) const
overrideprotectedvirtual

This method must be impemented by derived classes to return the pairs of images and ROIs (ROI may be null if no ROI is needed) for which data are needed.

Implements QmitkDataGeneratorBase.

◆ GetImageNodes()

ConstNodeVectorType QmitkImageAndRoiDataGeneratorBase::GetImageNodes ( ) const

◆ GetROINodes()

ConstNodeVectorType QmitkImageAndRoiDataGeneratorBase::GetROINodes ( ) const

◆ operator=()

QmitkImageAndRoiDataGeneratorBase& QmitkImageAndRoiDataGeneratorBase::operator= ( const QmitkImageAndRoiDataGeneratorBase )
protecteddelete

◆ SetImageNodes [1/2]

void QmitkImageAndRoiDataGeneratorBase::SetImageNodes ( const ConstNodeVectorType imageNodes)
slot

Setter for image nodes.

◆ SetImageNodes [2/2]

void QmitkImageAndRoiDataGeneratorBase::SetImageNodes ( const NodeVectorType imageNodes)
slot

Convinience overload

◆ SetROINodes [1/2]

void QmitkImageAndRoiDataGeneratorBase::SetROINodes ( const ConstNodeVectorType roiNodes)
slot

Setter for roi nodes.

◆ SetROINodes [2/2]

void QmitkImageAndRoiDataGeneratorBase::SetROINodes ( const NodeVectorType roiNodes)
slot

Convinience overload

Member Data Documentation

◆ m_ImageNodes

ConstNodeVectorType QmitkImageAndRoiDataGeneratorBase::m_ImageNodes
protected

Definition at line 58 of file QmitkImageAndRoiDataGeneratorBase.h.

◆ m_ROINodes

ConstNodeVectorType QmitkImageAndRoiDataGeneratorBase::m_ROINodes
protected

Definition at line 59 of file QmitkImageAndRoiDataGeneratorBase.h.


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