Slicer 5.13
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
Loading...
Searching...
No Matches
vtkMRMLOperationProgress.h
Go to the documentation of this file.
1/*==============================================================================
2
3 Program: 3D Slicer
4
5 See COPYRIGHT.txt
6 or http://www.slicer.org/copyright/copyright.txt for details.
7
8 Unless required by applicable law or agreed to in writing, software
9 distributed under the License is distributed on an "AS IS" BASIS,
10 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 See the License for the specific language governing permissions and
12 limitations under the License.
13
14==============================================================================*/
15
16#ifndef __vtkMRMLOperationProgress_h
17#define __vtkMRMLOperationProgress_h
18
19#include "vtkMRMLLogicExport.h"
20
21#include <vtkObject.h>
22
23#include <string>
24
51class VTK_MRML_LOGIC_EXPORT vtkMRMLOperationProgress : public vtkObject
52{
53public:
55 vtkTypeMacro(vtkMRMLOperationProgress, vtkObject);
56 void PrintSelf(ostream& os, vtkIndent indent) override;
57
60 vtkGetMacro(Progress, double);
61 vtkSetClampMacro(Progress, double, 0.0, 1.0);
62
64 vtkGetMacro(Title, std::string);
65 vtkSetMacro(Title, std::string);
66
68 vtkGetMacro(ProgressText, std::string);
69 vtkSetMacro(ProgressText, std::string);
70
75 vtkGetMacro(NumberOfFiles, int);
76 vtkSetMacro(NumberOfFiles, int);
77
79 vtkGetMacro(CurrentFileIndex, int);
80 vtkSetMacro(CurrentFileIndex, int);
81
84 vtkGetMacro(CurrentFileProgress, double);
85 vtkSetClampMacro(CurrentFileProgress, double, -1.0, 1.0);
86
88
91 vtkGetMacro(ProgressRangeMinimum, double);
92 vtkSetClampMacro(ProgressRangeMinimum, double, 0.0, 1.0);
93 vtkGetMacro(ProgressRangeMaximum, double);
94 vtkSetClampMacro(ProgressRangeMaximum, double, 0.0, 1.0);
96 vtkGetMacro(CurrentFileRangeMinimum, double);
97 vtkSetClampMacro(CurrentFileRangeMinimum, double, 0.0, 1.0);
98 vtkGetMacro(CurrentFileRangeMaximum, double);
99 vtkSetClampMacro(CurrentFileRangeMaximum, double, 0.0, 1.0);
101
104 vtkGetMacro(Abortable, bool);
105 vtkSetMacro(Abortable, bool);
106 vtkBooleanMacro(Abortable, bool);
107
111 vtkGetMacro(AbortExecute, bool);
112 vtkSetMacro(AbortExecute, bool);
113 vtkBooleanMacro(AbortExecute, bool);
114
115protected:
118
119 double Progress{ 0.0 };
120 std::string Title;
121 std::string ProgressText;
124 double CurrentFileProgress{ -1.0 };
125 double ProgressRangeMinimum{ 0.0 };
126 double ProgressRangeMaximum{ 1.0 };
129 bool Abortable{ false };
130 bool AbortExecute{ false };
131
132private:
134 void operator=(const vtkMRMLOperationProgress&) = delete;
135};
136
137#endif
Progress of a long operation, such as loading files.
void PrintSelf(ostream &os, vtkIndent indent) override
static vtkMRMLOperationProgress * New()
~vtkMRMLOperationProgress() override