VTK
vtkPassArrays.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPassArrays.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 =========================================================================*/
15 /*-------------------------------------------------------------------------
16  Copyright 2008 Sandia Corporation.
17  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
18  the U.S. Government retains certain rights in this software.
19 -------------------------------------------------------------------------*/
66 #ifndef vtkPassArrays_h
67 #define vtkPassArrays_h
68 
69 #include "vtkFiltersGeneralModule.h" // For export macro
70 #include "vtkDataObjectAlgorithm.h"
71 
72 class VTKFILTERSGENERAL_EXPORT vtkPassArrays : public vtkDataObjectAlgorithm
73 {
74 public:
75  static vtkPassArrays* New();
77  void PrintSelf(ostream& os, vtkIndent indent) override;
78 
85  virtual void AddArray(int fieldType, const char* name);
86 
87  virtual void AddPointDataArray(const char* name);
88  virtual void AddCellDataArray(const char* name);
89  virtual void AddFieldDataArray(const char* name);
90 
91  virtual void RemoveArray(int fieldType, const char* name);
92 
93  virtual void RemovePointDataArray(const char* name);
94  virtual void RemoveCellDataArray(const char* name);
95  virtual void RemoveFieldDataArray(const char* name);
96 
98 
101  virtual void ClearArrays();
102  virtual void ClearPointDataArrays();
103  virtual void ClearCellDataArrays();
104  virtual void ClearFieldDataArrays();
106 
108 
112  vtkSetMacro(RemoveArrays, bool);
113  vtkGetMacro(RemoveArrays, bool);
114  vtkBooleanMacro(RemoveArrays, bool);
116 
118 
123  vtkSetMacro(UseFieldTypes, bool);
124  vtkGetMacro(UseFieldTypes, bool);
125  vtkBooleanMacro(UseFieldTypes, bool);
127 
135  virtual void AddFieldType(int fieldType);
136 
140  virtual void ClearFieldTypes();
141 
145  int ProcessRequest(vtkInformation* request,
146  vtkInformationVector** inputVector,
147  vtkInformationVector* outputVector) override;
148 
149 protected:
150  vtkPassArrays();
151  ~vtkPassArrays() override;
152 
157  int FillInputPortInformation(int port, vtkInformation* info) override;
158 
162  int RequestDataObject(vtkInformation* request,
163  vtkInformationVector** inputVector,
164  vtkInformationVector* outputVector) override;
165 
166  int RequestData(
169  vtkInformationVector*) override;
170 
173 
174  class Internals;
175  Internals* Implementation;
176 
177 private:
178  vtkPassArrays(const vtkPassArrays&) = delete;
179  void operator=(const vtkPassArrays&) = delete;
180 };
181 
182 #endif
183 
virtual int RequestDataObject(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.
Store vtkAlgorithm input/output information.
static vtkDataObjectAlgorithm * New()
Passes a subset of arrays to the output.
Definition: vtkPassArrays.h:72
a simple class to control print indentation
Definition: vtkIndent.h:39
int ProcessRequest(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
see vtkAlgorithm for details
Superclass for algorithms that produce only data object as output.
Internals * Implementation
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
Store zero or more vtkInformation instances.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.