VTK  9.1.0
vtkMutableGraphHelper.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkMutableGraphHelper.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----------------------------------------------------------------------------*/
43#ifndef vtkMutableGraphHelper_h
44#define vtkMutableGraphHelper_h
45
46#include "vtkGraph.h" // For vtkEdgeType
47#include "vtkInfovisCoreModule.h" // For export macro
48#include "vtkObject.h"
49
51class vtkGraph;
52class vtkGraphEdge;
55
56class VTKINFOVISCORE_EXPORT vtkMutableGraphHelper : public vtkObject
57{
58public:
61 void PrintSelf(ostream& os, vtkIndent indent) override;
62
64
72
77
79
84
89
94
99
104
105protected:
108
109 vtkGetObjectMacro(InternalGraph, vtkGraph);
112
114
117
118private:
120 void operator=(const vtkMutableGraphHelper&) = delete;
121};
122
123#endif
represent and manipulate attribute data in a dataset
Representation of a single graph edge.
Definition: vtkGraphEdge.h:40
Base class for graph data types.
Definition: vtkGraph.h:299
dynamic, self-adjusting array of vtkIdType
a simple class to control print indentation
Definition: vtkIndent.h:43
An editable directed graph.
Helper class for building a directed or directed graph.
vtkMutableUndirectedGraph * UndirectedGraph
void SetGraph(vtkGraph *g)
Set the underlying graph that you want to modify with this helper.
vtkMutableDirectedGraph * DirectedGraph
static vtkMutableGraphHelper * New()
vtkEdgeType AddEdge(vtkIdType u, vtkIdType v)
Add an edge to the underlying mutable graph.
void RemoveVertex(vtkIdType v)
Remove a vertex from the underlying mutable graph.
vtkIdType AddVertex()
Add a vertex to the underlying mutable graph.
vtkGraph * GetGraph()
Set the underlying graph that you want to modify with this helper.
void RemoveVertices(vtkIdTypeArray *verts)
Remove a collection of vertices from the underlying mutable graph.
void SetInternalGraph(vtkGraph *g)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
~vtkMutableGraphHelper() override
vtkGraphEdge * AddGraphEdge(vtkIdType u, vtkIdType v)
void RemoveEdge(vtkIdType e)
Remove an edge from the underlying mutable graph.
void RemoveEdges(vtkIdTypeArray *edges)
Remove a collection of edges from the underlying mutable graph.
An editable undirected graph.
abstract base class for most VTK objects
Definition: vtkObject.h:63
std::pair< boost::graph_traits< vtkGraph * >::edge_iterator, boost::graph_traits< vtkGraph * >::edge_iterator > edges(vtkGraph *g)
int vtkIdType
Definition: vtkType.h:332