Slicer 5.11
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 <iostream>
15#include <string>
16
50
51class vtkPluginWatcherStart;
52class vtkPluginWatcherEnd;
53class vtkPluginWatcherProgress;
54
55class VTK_SLICER_BASE_CLI_EXPORT vtkPluginFilterWatcher
56{
57public:
60 vtkPluginFilterWatcher(vtkAlgorithm* o, const char* comment = "", ModuleProcessInformation* inf = nullptr, double fraction = 1.0, double start = 0.0);
61
64
67 const char* GetNameOfClass() { return (Process ? Process->GetClassName() : "None"); }
68
72 void QuietOn() { this->SetQuiet(true); };
73 void QuietOff() { this->SetQuiet(false); };
74
77 vtkAlgorithm* GetProcess() { return Process; };
78
80 void SetSteps(int val) { Steps = val; };
81 int GetSteps() { return Steps; };
82
84 double GetStart() { return this->Start; };
85 double GetFraction() { return this->Fraction; };
86
89 void SetQuiet(bool val);
90 bool GetQuiet() { return Quiet; };
91
93 std::string GetComment() { return Comment; };
94
96 ModuleProcessInformation* GetProcessInformation() { return this->ProcessInformation; };
97
98protected:
99private:
100 int Steps;
101 bool Quiet;
102 std::string Comment;
103 vtkAlgorithm* Process;
104
105 ModuleProcessInformation* ProcessInformation;
106 double Fraction;
107 double Start;
108
109 vtkPluginWatcherStart* StartFilterCommand;
110 vtkPluginWatcherEnd* EndFilterCommand;
111 vtkPluginWatcherProgress* ProgressFilterCommand;
112
113 unsigned long StartTag;
114 unsigned long EndTag;
115 unsigned long ProgressTag;
116};
117
118#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)