Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitkIPersistable.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 #ifndef mitkIPersistable_h
13 #define mitkIPersistable_h
14 #include <string>
15 
16 namespace mitk
17 {
29  {
30  public:
37  virtual bool Save(const std::string &fileName = "") = 0;
38 
45  virtual bool Load(const std::string &fileName = "") = 0;
46 
52  virtual void SetId(const std::string &id) = 0;
53 
59  virtual std::string GetId() const = 0;
60  };
61 }
62 
63 #endif
#define MITKPERSISTENCE_EXPORT
Abstract interface for objects that can persist their state to and from files.
virtual void SetId(const std::string &id)=0
Set the unique identifier for this persistable object.
virtual bool Save(const std::string &fileName="")=0
Save the object's state to a file.
virtual bool Load(const std::string &fileName="")=0
Load the object's state from a file.
virtual std::string GetId() const =0
Get the unique identifier of this persistable object.
Find image slices visible on a given plane.