Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitkPropertyExtensions.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 mitkPropertyExtensions_h
18 #define mitkPropertyExtensions_h
19 
20 #include <map>
22 
23 namespace mitk
24 {
26  {
27  public:
30 
31  bool AddExtension(const std::string &propertyName,
33  const std::string &className,
34  bool overwrite) override;
35  PropertyExtension::Pointer GetExtension(const std::string &propertyName, const std::string &className) override;
36  bool HasExtension(const std::string &propertyName, const std::string &className) override;
37  void RemoveAllExtensions(const std::string &className) override;
38  void RemoveExtension(const std::string &propertyName, const std::string &className) override;
39 
40  private:
41  typedef std::map<std::string, PropertyExtension::Pointer> ExtensionMap;
42  typedef ExtensionMap::const_iterator ExtensionMapConstIterator;
43  typedef ExtensionMap::iterator ExtensionMapIterator;
44 
46  PropertyExtensions &operator=(const PropertyExtensions &);
47 
48  std::map<std::string, ExtensionMap> m_Extensions;
49  };
50 }
51 
52 #endif
PropertyExtension::Pointer GetExtension(const std::string &propertyName, const std::string &className) override
Get the extension of a specific property.
DataCollection - Class to facilitate loading/accessing structured data.
Interface of property extensions service.
void RemoveExtension(const std::string &propertyName, const std::string &className) override
Remove extension of a specific property.
bool HasExtension(const std::string &propertyName, const std::string &className) override
Check if a specific property has an extension.
void RemoveAllExtensions(const std::string &className) override
Remove all property extensions.
bool AddExtension(const std::string &propertyName, PropertyExtension::Pointer extension, const std::string &className, bool overwrite) override
Add an extension to a specific property.