MeVisLab Toolbox Reference
mlDicomEncapsulatedDocumentSeriesModuleTagInterface.h
Go to the documentation of this file.
1 // Copyright (c) Fraunhofer MEVIS, Germany. All rights reserved.
2 // **InsertLicense** code
3 //----------------------------------------------------------------------------------
5 
10 //----------------------------------------------------------------------------------
11 #pragma once
12 
17 
18 ML_START_NAMESPACE
19 
20 //----------------------------------------------------------------------------------
22 //----------------------------------------------------------------------------------
24 {
25 public:
32  const std::string &modality="");
33 
35  void setModality(const std::string &modality);
36 
38  std::string getModality() const;
39 
41  void addFields() override;
42 
44  void inheritValues(DCMTree::Const_TreePtr dcmTree) override;
45 
47  std::string applyModifications(DCMTree::TreePtr dcmTree,
48  const FieldContainer *treeInfos=nullptr) override;
49 
52 
54  std::string checkConsistency() const override;
55 
57  // NOTE: Although the modality tag is part of the encapsulated document series module it is not provided
58  // as field here, because normally it should not be editable by users. DICOM export
59  // modules typically have to set it manually.
60 
63 
68 
71 
72 public:
75 
76 protected:
78  std::string _modality;
79 };
80 
81 ML_END_NAMESPACE
Project global and OS specific declarations.
#define MLDICOMTAGINTERFACES_EXPORT
DLL export macro definition.
Field to encapsulate a boolean value.
Definition: mlFields.h:62
Provides control to copy/inherit a set of tag (values) from an input DCMTree, buffer it,...
Manages the module field interface according to DICOM General Series, C.24.1.
void addFields() override
Add fields to field container of module.
std::string checkConsistency() const override
Checks for invalid parameters; return textual description on error, or empty string on success.
DicomEncapsulatedDocumentSeriesModuleTagInterface(Module &modRef, const std::string &modality="")
Constructor, setting the reference of the module for which the fields shall be managed.
std::string _modality
If not empty then the content will be set as Modality tag, otherwise ignored.
StringField * _seriesNumberFld
Content of the corresponding DICOM tag definition.
BoolField * _inheritSeriesNumberFld
If true then the seriesNumber field is overwritten with inherited states, otherwise not.
void setModality(const std::string &modality)
Sets the modality value to be used; if an empty string is used, then no modality tag is set.
std::string getModality() const
Returns the currently set document type as string or an empty string if not set.
DicomCopyTagSetInterface _otherEncapsulatedDocumentSeriesTags
All other Encapsulated Document Series tags not available in the interface, allow public access.
StringField * _seriesDescriptionFld
Describes the series for which this DICOM file is created.
FieldAddOnBase::FieldChangeState handleFieldChanges(Field *field) override
Handle field notifications.
void inheritValues(DCMTree::Const_TreePtr dcmTree) override
Implements the copy of tag values from the given dcmTree to the fields.
std::string applyModifications(DCMTree::TreePtr dcmTree, const FieldContainer *treeInfos=nullptr) override
See DicomModifyFieldAddOnBase::applyModifications() for documentation.
The class DicomModifyFieldAddOnBase is dedicated to manage fields for ML modules and instances derive...
FieldAddOn class supporting inheritance and auto creating tag values (for example DICOM UIDs or tag v...
FieldChangeState
Describes the type of a field changes detected in handleFieldChanges(Field *field).
Defines the class FieldContainer to encapsulate a vector of fields for (see class Field).
Base class for all fields used in the ML.
Definition: mlField.h:73
Base class for an image processing module of the ML.
Definition: mlModule.h:156
Field to encapsulate a string value.
Definition: mlFields.h:1000
Header file for the ML module base class DicomCopyTagSetInterface which provides control to copy/inhe...
Header file of the DicomModifyFieldAddOnBase class dedicated to manage fields for ML modules and inst...
Header file for the FieldAddOn supporting inheritance and auto creating tag values (for example DICOM...
boost::shared_ptr< const Tree > Const_TreePtr
Definition: DCMTree_Lib.h:73
boost::shared_ptr< Tree > TreePtr
shared pointer to a DCMTree::Tree
Definition: DCMTree_Lib.h:70