VTK  9.1.0
vtkAppendSelection.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkAppendSelection.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 (c) Sandia Corporation
17  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
18 ----------------------------------------------------------------------------*/
29 #ifndef vtkAppendSelection_h
30 #define vtkAppendSelection_h
31 
32 #include "vtkFiltersCoreModule.h" // For export macro
33 #include "vtkSelectionAlgorithm.h"
34 
35 class vtkSelection;
36 
37 class VTKFILTERSCORE_EXPORT vtkAppendSelection : public vtkSelectionAlgorithm
38 {
39 public:
41 
43  void PrintSelf(ostream& os, vtkIndent indent) override;
44 
46 
52  vtkSetMacro(UserManagedInputs, vtkTypeBool);
53  vtkGetMacro(UserManagedInputs, vtkTypeBool);
54  vtkBooleanMacro(UserManagedInputs, vtkTypeBool);
56 
62 
68 
70 
74  vtkSelection* GetInput() { return this->GetInput(0); }
76 
81  void SetNumberOfInputs(int num);
82 
83  // Set Nth input, should only be used when UserManagedInputs is true.
85 
87 
95  vtkSetMacro(AppendByUnion, vtkTypeBool);
96  vtkGetMacro(AppendByUnion, vtkTypeBool);
97  vtkBooleanMacro(AppendByUnion, vtkTypeBool);
99 
100 protected:
103 
104  // Usual data generation method
107 
108 private:
109  // hide the superclass' AddInput() from the user and the compiler
110  void AddInputData(vtkDataObject*)
111  {
112  vtkErrorMacro(<< "AddInput() must be called with a vtkSelection not a vtkDataObject.");
113  }
114 
115  vtkTypeBool UserManagedInputs;
116  vtkTypeBool AppendByUnion;
117 
118 private:
119  vtkAppendSelection(const vtkAppendSelection&) = delete;
120  void operator=(const vtkAppendSelection&) = delete;
121 };
122 
123 #endif
Proxy object to connect input/output ports.
appends one or more selections together
static vtkAppendSelection * New()
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
vtkSelection * GetInput(int idx)
Get any input of this filter.
void SetNumberOfInputs(int num)
Directly set(allocate) number of inputs, should only be used when UserManagedInputs is true.
vtkSelection * GetInput()
Get any input of this filter.
void SetInputConnectionByNumber(int num, vtkAlgorithmOutput *input)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int FillInputPortInformation(int, vtkInformation *) override
Fill the input port information objects for this algorithm.
void RemoveInputData(vtkSelection *)
Remove a dataset from the list of data to append.
~vtkAppendSelection() override
void AddInputData(vtkSelection *)
Add a dataset to the list of data to append.
general representation of visualization data
Definition: vtkDataObject.h:60
a simple class to control print indentation
Definition: vtkIndent.h:34
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce only Selection as output.
data object that represents a "selection" in VTK.
Definition: vtkSelection.h:54
int vtkTypeBool
Definition: vtkABI.h:69