VTK  9.4.20241118
vtkCompositeDataIterator.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
14#ifndef vtkCompositeDataIterator_h
15#define vtkCompositeDataIterator_h
16
17#include "vtkCommonDataModelModule.h" // For export macro
18#include "vtkObject.h"
19
20VTK_ABI_NAMESPACE_BEGIN
22class vtkCompositeDataSetInternals;
23class vtkCompositeDataSetIndex;
24class vtkDataObject;
25class vtkInformation;
26
27class VTKCOMMONDATAMODEL_EXPORT vtkCompositeDataIterator : public vtkObject
28{
29public:
31 void PrintSelf(ostream& os, vtkIndent indent) override;
32
34
39 vtkGetObjectMacro(DataSet, vtkCompositeDataSet);
41
45 virtual void InitTraversal();
46
50 virtual void InitReverseTraversal();
51
55 virtual void GoToFirstItem() = 0;
56
60 virtual void GoToNextItem() = 0;
61
68 virtual int IsDoneWithTraversal() = 0;
69
74
81
87
89
93 vtkSetMacro(SkipEmptyNodes, vtkTypeBool);
94 vtkGetMacro(SkipEmptyNodes, vtkTypeBool);
95 vtkBooleanMacro(SkipEmptyNodes, vtkTypeBool);
97
101 virtual unsigned int GetCurrentFlatIndex() = 0;
102
104
107 vtkGetMacro(Reverse, int);
109
110protected:
113
114 // Use macro to ensure MTime is updated:
115 vtkSetMacro(Reverse, int);
116
120
121private:
123 void operator=(const vtkCompositeDataIterator&) = delete;
124};
125
126VTK_ABI_NAMESPACE_END
127#endif
superclass for composite data iterators
~vtkCompositeDataIterator() override
virtual void SetDataSet(vtkCompositeDataSet *ds)
Set the composite dataset this iterator is iterating over.
virtual void InitReverseTraversal()
Begin iterating over the composite dataset structure in reverse order.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual int IsDoneWithTraversal()=0
Test whether the iterator is finished with the traversal.
virtual void GoToFirstItem()=0
Move the iterator to the beginning of the collection.
virtual vtkTypeBool HasCurrentMetaData()=0
Returns if the a meta-data information object is present for the current item.
virtual vtkInformation * GetCurrentMetaData()=0
Returns the meta-data associated with the current item.
virtual void InitTraversal()
Begin iterating over the composite dataset structure.
virtual vtkDataObject * GetCurrentDataObject()=0
Returns the current item.
virtual void GoToNextItem()=0
Move the iterator to the next item in the collection.
virtual unsigned int GetCurrentFlatIndex()=0
Flat index is an index to identify the data in a composite data structure.
abstract superclass for composite (multi-block or AMR) datasets
general representation of visualization data
a simple class to control print indentation
Definition vtkIndent.h:108
Store vtkAlgorithm input/output information.
abstract base class for most VTK objects
Definition vtkObject.h:162
int vtkTypeBool
Definition vtkABI.h:64