VTK  9.5.20250803
vtkAbstractCellLinks.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
19#ifndef vtkAbstractCellLinks_h
20#define vtkAbstractCellLinks_h
21
22#include "vtkCommonDataModelModule.h" // For export macro
23#include "vtkDeprecation.h" // For VTK_DEPRECATED_IN_9_5_0
24#include "vtkObject.h"
25#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
26
27VTK_ABI_NAMESPACE_BEGIN
28class vtkDataSet;
29class vtkCellArray;
30class vtkIdList;
31
32class VTKCOMMONDATAMODEL_EXPORT VTK_MARSHALAUTO vtkAbstractCellLinks : public vtkObject
33{
34public:
36
40 void PrintSelf(ostream& os, vtkIndent indent) override;
42
44
47 virtual void SetDataSet(vtkDataSet*);
48 vtkGetObjectMacro(DataSet, vtkDataSet);
50
54 virtual void BuildLinks() = 0;
55
59 virtual void Initialize() = 0;
60
64 virtual void Squeeze() = 0;
65
69 virtual void Reset() = 0;
70
79 virtual unsigned long GetActualMemorySize() = 0;
80
86 virtual void DeepCopy(vtkAbstractCellLinks* src) = 0;
87
93 virtual void ShallowCopy(vtkAbstractCellLinks* src) = 0;
94
95 // Enums for cell links type. Note that the specialized type is
96 // set when users do not use ComputeType() and roll their own type.
98 {
99 LINKS_NOT_DEFINED = 0,
100 CELL_LINKS = 1,
101 STATIC_CELL_LINKS_USHORT = 2,
102 STATIC_CELL_LINKS_UINT = 3,
103 STATIC_CELL_LINKS_IDTYPE = 4,
104 STATIC_CELL_LINKS_SPECIALIZED = 5
105 };
106
118 static int ComputeType(vtkIdType maxPtId, vtkIdType maxCellId, vtkCellArray* ca);
119 static int ComputeType(vtkIdType maxPtId, vtkIdType maxCellId, vtkIdType connectivitySize);
120
124 vtkGetMacro(Type, int);
125
140
147 virtual void SelectCells(vtkIdType minMaxDegree[2], unsigned char* cellSelection) = 0;
149
151
159 VTK_DEPRECATED_IN_9_5_0("No longer used.")
160 vtkSetMacro(SequentialProcessing, bool);
161 VTK_DEPRECATED_IN_9_5_0("No longer used.")
162 vtkGetMacro(SequentialProcessing, bool);
163 VTK_DEPRECATED_IN_9_5_0("No longer used.")
164 virtual void SequentialProcessingOn()
165 {
166 if (!this->SequentialProcessing)
167 {
168 this->SequentialProcessing = true;
169 this->Modified();
170 }
171 }
172 VTK_DEPRECATED_IN_9_5_0("No longer used.")
173 virtual void SequentialProcessingOff()
174 {
175 if (this->SequentialProcessing)
176 {
177 this->SequentialProcessing = false;
178 this->Modified();
179 }
180 }
182
184
187 vtkGetMacro(BuildTime, vtkMTimeType);
189
191
194 bool UsesGarbageCollector() const override { return true; }
196protected:
199
201 // VTK_DEPRECATED_IN_9_5_0("No longer used.")
202 bool SequentialProcessing; // control whether to thread or not
203 int Type; // derived classes set this instance variable when constructed
204
205 vtkTimeStamp BuildTime; // time at which links were built
206
208
209private:
211 void operator=(const vtkAbstractCellLinks&) = delete;
212};
213
214VTK_ABI_NAMESPACE_END
215#endif
object to represent cell connectivity
abstract class to specify dataset behavior
Definition vtkDataSet.h:165
Detect and break reference loops.
list of point or cell ids
Definition vtkIdList.h:133
a simple class to control print indentation
Definition vtkIndent.h:108
abstract base class for most VTK objects
Definition vtkObject.h:162
virtual void Modified()
Update the modification time for this object.
record modification and/or execution time
#define VTK_DEPRECATED_IN_9_5_0(reason)
int vtkIdType
Definition vtkType.h:332
vtkTypeUInt32 vtkMTimeType
Definition vtkType.h:287
#define VTK_MARSHALAUTO