VTK
vtkPlaneCollection.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPlaneCollection.h
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 =========================================================================*/
27 #ifndef vtkPlaneCollection_h
28 #define vtkPlaneCollection_h
29 
30 #include "vtkCommonDataModelModule.h" // For export macro
31 #include "vtkCollection.h"
32 
33 #include "vtkPlane.h" // Needed for inline methods
34 
36 {
37 public:
39  static vtkPlaneCollection *New();
40 
42  void AddItem(vtkPlane *);
43 
45  vtkPlane *GetNextItem();
46 
48 
49  vtkPlane *GetItem(int i) {
50  return static_cast<vtkPlane *>(this->GetItemAsObject(i));};
52 
53  //BTX
55 
57  vtkPlane *GetNextPlane(vtkCollectionSimpleIterator &cookie);
58  //ETX
60 
61 protected:
64 
65 
66 private:
67  // hide the standard AddItem from the user and the compiler.
68  void AddItem(vtkObject *o) { this->vtkCollection::AddItem(o); };
69 
70 private:
71  vtkPlaneCollection(const vtkPlaneCollection&); // Not implemented.
72  void operator=(const vtkPlaneCollection&); // Not implemented.
73 };
74 
76 {
77  this->vtkCollection::AddItem(f);
78 }
79 
81 {
82  return static_cast<vtkPlane *>(this->GetNextItemAsObject());
83 }
84 
85 #endif
86 // VTK-HeaderTest-Exclude: vtkPlaneCollection.h
void * vtkCollectionSimpleIterator
Definition: vtkCollection.h:47
vtkPlane * GetItem(int i)
abstract base class for most VTK objects
Definition: vtkObject.h:61
maintain a list of planes
static vtkCollection * New()
perform various plane computations
Definition: vtkPlane.h:36
vtkPlane * GetNextItem()
void AddItem(vtkObject *)
create and manipulate unsorted lists of objects
Definition: vtkCollection.h:52
void AddItem(vtkPlane *)
vtkObject * GetNextItemAsObject()
vtkObject * GetItemAsObject(int i)
#define VTKCOMMONDATAMODEL_EXPORT