Medical Imaging Interaction Toolkit  2023.04.00
Medical Imaging Interaction Toolkit
mitkSemanticRelationsIntegration.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 
13 #ifndef mitkSemanticRelationsIntegration_h
14 #define mitkSemanticRelationsIntegration_h
15 
17 
18 // semantic relations module
21 #include "mitkSemanticTypes.h"
22 
23 // mitk core
24 #include <mitkDataNode.h>
25 
26 namespace mitk
27 {
44  {
45  public:
46 
47  /************************************************************************/
48  /* functions to implement the observer pattern */
49  /************************************************************************/
56  void AddObserver(ISemanticRelationsObserver* observer) override;
62  void RemoveObserver(ISemanticRelationsObserver* observer) override;
63 
65 
66  /************************************************************************/
67  /* functions to add / remove instances / attributes */
68  /************************************************************************/
81  void AddImage(const DataNode* imageNode);
90  void RemoveImage(const DataNode* imageNode);
100  void AddLesion(const SemanticTypes::CaseID& caseID, const SemanticTypes::Lesion& lesion);
110  void OverwriteLesion(const SemanticTypes::CaseID& caseID, const SemanticTypes::Lesion& lesion);
124  void AddLesionAndLinkSegmentation(const DataNode* segmentationNode, const SemanticTypes::Lesion& lesion);
136  void RemoveLesion(const SemanticTypes::CaseID& caseID, const SemanticTypes::Lesion& lesion);
143  void AddSegmentation(const DataNode* segmentationNode, const DataNode* parentNode);
156  void LinkSegmentationToLesion(const DataNode* segmentationNode, const SemanticTypes::Lesion& lesion);
166  void UnlinkSegmentationFromLesion(const DataNode* segmentationNode);
175  void RemoveSegmentation(const DataNode* segmentationNode);
185  void SetControlPointOfImage(const DataNode* imageNode, const SemanticTypes::ControlPoint& controlPoint);
203  void AddControlPointAndLinkImage(const DataNode* imageNode, const SemanticTypes::ControlPoint& controlPoint, bool checkConsistence = true);
218  void LinkImageToControlPoint(const DataNode* imageNode, const SemanticTypes::ControlPoint& controlPoint, bool checkConsistence = true);
227  void UnlinkImageFromControlPoint(const DataNode* imageNode);
237  void AddExaminationPeriod(const SemanticTypes::CaseID& caseID, const SemanticTypes::ExaminationPeriod& examinationPeriod);
247  void RenameExaminationPeriod(const SemanticTypes::CaseID& caseID, const SemanticTypes::ExaminationPeriod& examinationPeriod);
260  void AddControlPointToExaminationPeriod(const SemanticTypes::CaseID& caseID, const SemanticTypes::ControlPoint& controlPoint, const SemanticTypes::ExaminationPeriod& examinationPeriod);
272  void SetInformationType(const DataNode* imageNode, const SemanticTypes::InformationType& informationType);
283  void AddInformationTypeToImage(const DataNode* imageNode, const SemanticTypes::InformationType& informationType);
295  void RemoveInformationTypeFromImage(const DataNode* imageNode);
296 
297  private:
301  static std::vector<mitk::ISemanticRelationsObserver*> m_ObserverVector;
309  void NotifyObserver(const mitk::SemanticTypes::CaseID& caseID) const override;
317  void ClearControlPoints(const SemanticTypes::CaseID& caseID);
318 
319  };
320 } // namespace mitk
321 
322 #endif
mitk::RelationStorage::RemoveLesion
void RemoveLesion(const SemanticTypes::CaseID &caseID, const SemanticTypes::Lesion &lesion)
mitk::RelationStorage::UnlinkSegmentationFromLesion
void UnlinkSegmentationFromLesion(const SemanticTypes::CaseID &caseID, const SemanticTypes::ID &segmentationID)
MitkSemanticRelationsExports.h
mitk::ISemanticRelationsObservable
Definition: mitkISemanticRelationsObservable.h:25
mitk::RelationStorage::AddExaminationPeriod
void AddExaminationPeriod(const SemanticTypes::CaseID &caseID, const SemanticTypes::ExaminationPeriod &examinationPeriod)
mitk::RelationStorage::RemoveImage
void RemoveImage(const SemanticTypes::CaseID &caseID, const SemanticTypes::ID &imageID)
mitk::RelationStorage::AddImage
void AddImage(const SemanticTypes::CaseID &caseID, const SemanticTypes::ID &imageID)
mitk::RelationStorage::AddLesion
void AddLesion(const SemanticTypes::CaseID &caseID, const SemanticTypes::Lesion &lesion)
mitk::RelationStorage::RemoveInformationTypeFromImage
void RemoveInformationTypeFromImage(const SemanticTypes::CaseID &caseID, const SemanticTypes::ID &imageID)
mitkSemanticTypes.h
mitk::RelationStorage::LinkSegmentationToLesion
void LinkSegmentationToLesion(const SemanticTypes::CaseID &caseID, const SemanticTypes::ID &segmentationID, const SemanticTypes::Lesion &lesion)
mitk::RelationStorage::AddSegmentation
void AddSegmentation(const SemanticTypes::CaseID &caseID, const SemanticTypes::ID &segmentationID, const SemanticTypes::ID &parentID)
MITKSEMANTICRELATIONS_EXPORT
#define MITKSEMANTICRELATIONS_EXPORT
Definition: MitkSemanticRelationsExports.h:15
mitk::RelationStorage::UnlinkImageFromControlPoint
void UnlinkImageFromControlPoint(const SemanticTypes::CaseID &caseID, const SemanticTypes::ID &imageID)
mitk::SemanticTypes::ControlPoint
Definition: mitkSemanticTypes.h:40
mitk::SemanticTypes::Lesion
Definition: mitkSemanticTypes.h:108
mitk
DataCollection - Class to facilitate loading/accessing structured data.
Definition: RenderingTests.dox:1
mitk::RelationStorage::AddInformationTypeToImage
void AddInformationTypeToImage(const SemanticTypes::CaseID &caseID, const SemanticTypes::ID &imageID, const SemanticTypes::InformationType &informationType)
mitk::SemanticRelationsIntegration
The API provides functions to manipulate image relations and instances that are helpful during follow...
Definition: mitkSemanticRelationsIntegration.h:43
mitk::RelationStorage::OverwriteLesion
void OverwriteLesion(const SemanticTypes::CaseID &caseID, const SemanticTypes::Lesion &lesion)
mitk::SemanticTypes::CaseID
std::string CaseID
Definition: mitkSemanticTypes.h:34
mitk::SemanticRelationsIntegration::~SemanticRelationsIntegration
virtual ~SemanticRelationsIntegration()
Definition: mitkSemanticRelationsIntegration.h:64
mitk::RelationStorage::RenameExaminationPeriod
MITKSEMANTICRELATIONS_EXPORT void RenameExaminationPeriod(const SemanticTypes::CaseID &caseID, const SemanticTypes::ExaminationPeriod &examinationPeriod)
mitkDataNode.h
mitkISemanticRelationsObserver.h
mitk::RelationStorage::RemoveSegmentation
void RemoveSegmentation(const SemanticTypes::CaseID &caseID, const SemanticTypes::ID &segmentationID)
mitkISemanticRelationsObservable.h
mitk::DataNode
Class for nodes of the DataTree.
Definition: mitkDataNode.h:63
mitk::RelationStorage::LinkImageToControlPoint
void LinkImageToControlPoint(const SemanticTypes::CaseID &caseID, const SemanticTypes::ID &imageID, const SemanticTypes::ControlPoint &controlPoint)
mitk::ISemanticRelationsObserver
Definition: mitkISemanticRelationsObserver.h:24
mitk::SemanticTypes::ExaminationPeriod
The concept of an examination period. An examination period holds a vector of control point UIDs....
Definition: mitkSemanticTypes.h:89
mitk::SemanticTypes::InformationType
std::string InformationType
Definition: mitkSemanticTypes.h:35
mitk::RelationStorage::AddControlPointToExaminationPeriod
void AddControlPointToExaminationPeriod(const SemanticTypes::CaseID &caseID, const SemanticTypes::ControlPoint &controlPoint, const SemanticTypes::ExaminationPeriod &examinationPeriod)