VTK
vtkTreeIterator.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: $RCSfile: vtkTreeIterator.h,v $
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
15 
30 #ifndef __vtkTreeIterator_h
31 #define __vtkTreeIterator_h
32 
33 #include "vtkObject.h"
34 
35 class vtkTree;
36 
38 {
39 public:
40  vtkTypeMacro(vtkTreeIterator, vtkObject);
41  virtual void PrintSelf(ostream& os, vtkIndent indent);
42 
44 
45  void SetTree(vtkTree* graph);
46  vtkGetMacro(Tree, vtkTree*);
48 
50 
53  void SetStartVertex(vtkIdType vertex);
54  vtkGetMacro(StartVertex, vtkIdType);
56 
58  vtkIdType Next();
59 
61  bool HasNext();
62 
64  void Restart();
65 
66 protected:
68  ~vtkTreeIterator();
69 
70  virtual void Initialize() = 0;
71  virtual vtkIdType NextInternal() = 0;
72 
76 
77 private:
78  vtkTreeIterator(const vtkTreeIterator &); // Not implemented.
79  void operator=(const vtkTreeIterator &); // Not implemented.
80 };
81 
82 #endif