Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitkGizmoObjectFactory.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,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
17 #ifndef GizmoObjectFactor_h
18 #define GizmoObjectFactor_h
19 
20 // MITK includes
21 #include <mitkCoreObjectFactory.h>
22 
23 // Export definitions
24 #include <MitkGizmoExports.h>
25 
26 namespace mitk
27 {
28  /*
29  \brief Registers mappers and assigns default properties for mitk::Gizmo.
30 
31  This class is still required by MITK to register custom mappers.
32  The base class interface requires also methods that describe file
33  reader/writer extensions, but this is already deprecated. We do
34  not implement those methods but use the new micro-service registration
35  via GizmoActivator.
36  */
38  {
39  public:
41  itkFactorylessNewMacro(Self);
42  itkCloneMacro(Self);
43 
44  // Create a mapper for given node
45  virtual mitk::Mapper::Pointer CreateMapper(mitk::DataNode *node, MapperSlotId slotId) override;
46 
47  // Assign default properties to given node
48  virtual void SetDefaultProperties(mitk::DataNode *node) override;
49 
50  // Deprecated but required!
51  virtual const char *GetFileExtensions() override { return ""; }
52  // Deprecated but required!
54  {
56  }
57 
58  // Deprecated but required!
59  virtual const char *GetSaveFileExtensions() override { return ""; }
60  // Deprecated but required!
62  {
64  }
65  };
66 }
67 
68 #endif
#define MITKGIZMO_EXPORT
virtual const char * GetSaveFileExtensions() override
virtual const char * GetFileExtensions() override
DataCollection - Class to facilitate loading/accessing structured data.
#define mitkClassMacro(className, SuperClassName)
Definition: mitkCommon.h:44
virtual mitk::CoreObjectFactoryBase::MultimapType GetSaveFileExtensionsMap() override
virtual mitk::CoreObjectFactoryBase::MultimapType GetFileExtensionsMap() override
unsigned int MapperSlotId
Definition: mitkCommon.h:37
std::multimap< std::string, std::string > MultimapType
Class for nodes of the DataTree.
Definition: mitkDataNode.h:66