Slicer  4.10
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
vtkMRMLScriptedModuleNode.h
Go to the documentation of this file.
1 /*=auto=========================================================================
2 
3  Portions (c) Copyright 2005 Brigham and Women's Hospital (BWH) All Rights Reserved.
4 
5  See COPYRIGHT.txt
6  or http://www.slicer.org/copyright/copyright.txt for details.
7 
8  Program: 3D Slicer
9  Module: $RCSfile: vtkMRMLScriptedModuleNode.h,v $
10  Date: $Date: 2006/03/19 17:12:29 $
11  Version: $Revision: 1.3 $
12 
13 =========================================================================auto=*/
14 
15 #ifndef __vtkMRMLScriptedModuleNode_h
16 #define __vtkMRMLScriptedModuleNode_h
17 
18 // MRML includes
19 #include "vtkMRMLNode.h"
20 
21 // STD includes
22 #include <string>
23 #include <vector>
24 
27 class VTK_MRML_EXPORT vtkMRMLScriptedModuleNode : public vtkMRMLNode
28 {
29 public:
30  static vtkMRMLScriptedModuleNode *New();
32  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
33 
34  virtual vtkMRMLNode* CreateNodeInstance() VTK_OVERRIDE;
35 
37  virtual void ReadXMLAttributes( const char** atts) VTK_OVERRIDE;
38 
40  virtual void WriteXML(ostream& of, int indent) VTK_OVERRIDE;
41 
43  virtual void Copy(vtkMRMLNode *node) VTK_OVERRIDE;
44 
46  virtual const char* GetNodeTagName() VTK_OVERRIDE;
47 
50  vtkGetStringMacro (ModuleName);
51  vtkSetStringMacro (ModuleName);
52 
54  void SetParameter(const std::string& name, const std::string& value);
55 
57  void UnsetParameter(const std::string& name);
58 
61  void UnsetAllParameters();
62 
64  std::string GetParameter(const std::string& name) const;
65 
67  int GetParameterCount();
68 
71  std::string GetParameterNamesAsCommaSeparatedList();
72 
74  std::vector<std::string> GetParameterNames();
75 
76 protected:
79 
81  void operator=(const vtkMRMLScriptedModuleNode&);
82 
83  typedef std::map<std::string, std::string> ParameterMap;
84  ParameterMap Parameters;
85  char *ModuleName;
86 };
87 
88 #endif
LRU Cache.
virtual vtkMRMLNode * CreateNodeInstance()=0
Create instance of the default node. Like New only virtual.
std::map< std::string, std::string > ParameterMap
void PrintSelf(ostream &os, vtkIndent indent) VTK_OVERRIDE
Abstract Superclass for all specific types of MRML nodes.
Definition: vtkMRMLNode.h:138