Slicer 5.9
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
Loading...
Searching...
No Matches
vtkPluginFilterWatcher.h
Go to the documentation of this file.
1#ifndef __vtkPluginFilterWatcher_h
2#define __vtkPluginFilterWatcher_h
3
4// ModuleDescriptionParser includes
5#include <ModuleProcessInformation.h>
6
7// VTK includes
8#include <vtkCommand.h>
9#include <vtkAlgorithm.h>
10
11#include "vtkSlicerBaseCLIExport.h"
12
13// STD includes
14#include <string>
15
49
50class vtkPluginWatcherStart;
51class vtkPluginWatcherEnd;
52class vtkPluginWatcherProgress;
53
54class VTK_SLICER_BASE_CLI_EXPORT vtkPluginFilterWatcher
55{
56public:
59 vtkPluginFilterWatcher(vtkAlgorithm* o, const char* comment = "", ModuleProcessInformation* inf = nullptr, double fraction = 1.0, double start = 0.0);
60
63
66 const char* GetNameOfClass() { return (Process ? Process->GetClassName() : "None"); }
67
71 void QuietOn() { this->SetQuiet(true); };
72 void QuietOff() { this->SetQuiet(false); };
73
76 vtkAlgorithm* GetProcess() { return Process; };
77
79 void SetSteps(int val) { Steps = val; };
80 int GetSteps() { return Steps; };
81
83 double GetStart() { return this->Start; };
84 double GetFraction() { return this->Fraction; };
85
88 void SetQuiet(bool val);
89 bool GetQuiet() { return Quiet; };
90
92 std::string GetComment() { return Comment; };
93
95 ModuleProcessInformation* GetProcessInformation() { return this->ProcessInformation; };
96
97protected:
98private:
99 int Steps;
100 bool Quiet;
101 std::string Comment;
102 vtkAlgorithm* Process;
103
104 ModuleProcessInformation* ProcessInformation;
105 double Fraction;
106 double Start;
107
108 vtkPluginWatcherStart* StartFilterCommand;
109 vtkPluginWatcherEnd* EndFilterCommand;
110 vtkPluginWatcherProgress* ProgressFilterCommand;
111
112 unsigned long StartTag;
113 unsigned long EndTag;
114 unsigned long ProgressTag;
115};
116
117#endif
virtual ~vtkPluginFilterWatcher()
vtkPluginFilterWatcher(vtkAlgorithm *o, const char *comment="", ModuleProcessInformation *inf=nullptr, double fraction=1.0, double start=0.0)
ModuleProcessInformation * GetProcessInformation()
void SetQuiet(bool val)