Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitkBaseDataSerializer.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 mitkBaseDataSerializer_h
14 #define mitkBaseDataSerializer_h
15 
16 #include <mitkSerializerMacros.h>
18 
19 #include <mitkBaseData.h>
20 #include <itkObjectFactoryBase.h>
21 
22 namespace mitk
23 {
42  {
43  public:
45 
47  itkSetStringMacro(FilenameHint);
49  itkGetStringMacro(FilenameHint);
50 
52  itkSetStringMacro(WorkingDirectory);
54  itkGetStringMacro(WorkingDirectory);
55 
60  itkSetConstObjectMacro(Data, BaseData);
61 
75  virtual std::string Serialize();
76 
77  protected:
79  ~BaseDataSerializer() override;
80 
82 
83  std::string m_FilenameHint;
84  std::string m_WorkingDirectory;
85  BaseData::ConstPointer m_Data;
86  };
87 
88 } // namespace
89 
90 #endif
#define MITKSCENESERIALIZATIONBASE_EXPORT
Base class for objects that serialize BaseData types to files.
mitkClassMacroItkParent(BaseDataSerializer, itk::Object)
virtual std::string Serialize()
Serializes the previously set BaseData object to a file.
std::string GetUniqueFilenameInWorkingDirectory()
BaseData::ConstPointer m_Data
~BaseDataSerializer() override
Base class of all data objects.
Definition: mitkBaseData.h:60
Provides the MITK_REGISTER_SERIALIZER macro for automatic registration of serializer classes.
Find image slices visible on a given plane.