Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitkBindDispatcherInteractor.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 mitkBindDispatcherInteractor_h
14 #define mitkBindDispatcherInteractor_h
15 
16 #include <mitkCommon.h>
17 #include <MitkCoreExports.h>
18 
19 #include <mitkDataNode.h>
20 #include <mitkDataStorage.h>
21 #include <mitkDispatcher.h>
22 
23 namespace mitk
24 {
38  {
39  public:
44  BindDispatcherInteractor(const std::string &rendererName);
45 
48 
57  void SetDataStorage(DataStorage::Pointer dataStorage);
58 
67  void SetDispatcher(Dispatcher::Pointer dispatcher);
68 
73  Dispatcher::Pointer GetDispatcher() const;
74 
75  private:
82  void RegisterInteractor(const DataNode *dataNode);
83 
85  void UnRegisterInteractor(const DataNode *dataNode);
86 
88  void RegisterDataStorageEvents();
89 
91  void UnRegisterDataStorageEvents();
92 
93  Dispatcher::Pointer m_Dispatcher;
94  DataStorage::Pointer m_DataStorage;
95  };
96 }
97 #endif
#define MITKCORE_EXPORT
Connects a DataStorage with a Dispatcher for interaction event routing.
void SetDispatcher(Dispatcher::Pointer dispatcher)
Set the Dispatcher to be notified of data node changes.
Dispatcher::Pointer GetDispatcher() const
Return the currently active Dispatcher.
~BindDispatcherInteractor()
Destructor. Unregisters from the current DataStorage.
BindDispatcherInteractor(const std::string &rendererName)
Construct a BindDispatcherInteractor for the given renderer.
void SetDataStorage(DataStorage::Pointer dataStorage)
Set the DataStorage whose events this class subscribes to.
Central node class of the MITK data tree, associating a data object with properties and mappers.
Definition: mitkDataNode.h:72
Find image slices visible on a given plane.