MeVisLab Toolbox Reference
mlPrivateDICOMTagDecoderPluginBase.h
Go to the documentation of this file.
1 /*************************************************************************************
2 **
3 ** Copyright 2012, MeVis Medical Solutions AG
4 **
5 ** The user may use this file in accordance with the license agreement provided with
6 ** the Software or, alternatively, in accordance with the terms contained in a
7 ** written agreement between the user and MeVis Medical Solutions AG.
8 **
9 ** For further information use the contact form at https://www.mevislab.de/contact
10 **
11 **************************************************************************************/
12 
13 #ifndef ML_PRIVATE_DICOMTAG_DECODER_PLUGIN_BASE_H
14 #define ML_PRIVATE_DICOMTAG_DECODER_PLUGIN_BASE_H
15 
16 
18 
20 
22 
23 #include "mlBase.h"
24 
25 // DICOM classes.
26 #include <DCMTree_Lib.h>
27 
28 ML_START_NAMESPACE
29 
30 //----------------------------------------------------------------------------------
32 //----------------------------------------------------------------------------------
34 {
35  public:
36 
38  typedef std::map<DCMTree::RawTagId, std::string> PrivateCreatorIdMap;
39 
43 
46 
48  enum DecodeStates {
49  NOT_DECODED = 0,
51  FULLY_DECODED
52  };
53 
62  virtual DecodeStates decodePrivateTag(const std::string &privateCreator,
63  DCMTree::Const_TagPtr tagPtr,
64  PrivateDICOMTagValueFields &resultFields) = 0;
65 
67  inline PrivateCreatorIdMap *getPrivateCreatorMap() const { return _privateCreatorMap; }
68 
70  inline void setPrivateCreatorMap(PrivateCreatorIdMap *pcm) { _privateCreatorMap = pcm; }
71 
72  private:
73 
75  PrivateCreatorIdMap *_privateCreatorMap;
76 
79 };
80 
81 ML_END_NAMESPACE
82 
83 #endif
#define MLPRIVATEDICOMTAGDECODERS_EXPORT
Project global and OS specific declarations.
Class representing general ML objects that support import/export via strings (setPersistentState() an...
Definition: mlBase.h:62
Base class for plugins decoding private DICOM tags to a PrivateDICOMTagValueFields container.
void setPrivateCreatorMap(PrivateCreatorIdMap *pcm)
Sets the map which stores a set of known private creators, typically from the currently traversed DIC...
~PrivateDICOMTagDecoderPluginBase() override
Virtual destructor.
PrivateCreatorIdMap * getPrivateCreatorMap() const
Returns the map which stores a set of known private creators, typically from the currently traversed ...
PrivateDICOMTagDecoderPluginBase(PrivateCreatorIdMap *privateCreatorMap=nullptr)
Default constructor implementation creating a link symbol to make this base class always linked.
@ PARTIALLY_DECODED
The tag data could be decoded partially.
std::map< DCMTree::RawTagId, std::string > PrivateCreatorIdMap
A type storing tag group ids for strings found in private tags (tags with odd numbers and id 0x10-0xF...
virtual DecodeStates decodePrivateTag(const std::string &privateCreator, DCMTree::Const_TagPtr tagPtr, PrivateDICOMTagValueFields &resultFields)=0
When deriving a decoder for private tags then implement this method.
List type managing and maintaining a number of PrivateDICOMTagValueFields::PrivateTagField containers...
#define ML_ABSTRACT_CLASS_HEADER(className)
Same like ML_ABSTRACT_CLASS_HEADER_EXPORTED with a non existing export symbol.
boost::shared_ptr< const Tag > Const_TagPtr
Definition: DCMTree_Lib.h:63