VTK  9.3.0
vtkBoostBreadthFirstSearchTree.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-FileCopyrightText: Copyright 2008 Sandia Corporation
3 // SPDX-License-Identifier: LicenseRef-BSD-3-Clause-Sandia-USGov
23 #ifndef vtkBoostBreadthFirstSearchTree_h
24 #define vtkBoostBreadthFirstSearchTree_h
25 
26 #include "vtkInfovisBoostGraphAlgorithmsModule.h" // For export macro
27 #include "vtkStdString.h" // For string type
28 #include "vtkVariant.h" // For variant type
29 
30 #include "vtkTreeAlgorithm.h"
31 
32 VTK_ABI_NAMESPACE_BEGIN
33 class VTKINFOVISBOOSTGRAPHALGORITHMS_EXPORT vtkBoostBreadthFirstSearchTree : public vtkTreeAlgorithm
34 {
35 public:
38  void PrintSelf(ostream& os, vtkIndent indent) override;
39 
45 
54 
56 
60  vtkSetMacro(CreateGraphVertexIdArray, bool);
61  vtkGetMacro(CreateGraphVertexIdArray, bool);
62  vtkBooleanMacro(CreateGraphVertexIdArray, bool);
64 
66 
69  vtkSetMacro(ReverseEdges, bool);
70  vtkGetMacro(ReverseEdges, bool);
71  vtkBooleanMacro(ReverseEdges, bool);
73 
74 protected:
77 
79 
81 
82 private:
83  vtkIdType OriginVertexIndex;
84  char* ArrayName;
85  vtkVariant OriginValue;
86  bool ArrayNameSet;
87  bool CreateGraphVertexIdArray;
88  bool ReverseEdges;
89 
91 
94  vtkSetStringMacro(ArrayName);
96 
101  vtkIdType GetVertexIndex(vtkAbstractArray* abstract, vtkVariant value);
102 
104  void operator=(const vtkBoostBreadthFirstSearchTree&) = delete;
105 };
106 
107 VTK_ABI_NAMESPACE_END
108 #endif
Abstract superclass for all arrays.
Constructs a BFS tree from a graph.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
void SetOriginVertex(vtkStdString arrayName, vtkVariant value)
Set the breadth first search 'origin' vertex.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
static vtkBoostBreadthFirstSearchTree * New()
~vtkBoostBreadthFirstSearchTree() override
void SetOriginVertex(vtkIdType index)
Set the index (into the vertex array) of the breadth first search 'origin' vertex.
a simple class to control print indentation
Definition: vtkIndent.h:29
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Wrapper around std::string to keep symbols short.
Definition: vtkStdString.h:29
Superclass for algorithms that produce only Tree as output.
A type representing the union of many types.
Definition: vtkVariant.h:53
@ info
Definition: vtkX3D.h:376
@ value
Definition: vtkX3D.h:220
@ port
Definition: vtkX3D.h:447
@ index
Definition: vtkX3D.h:246
int vtkIdType
Definition: vtkType.h:315