Go to the documentation of this file.
41 #ifndef vtkMutableDirectedGraph_h
42 #define vtkMutableDirectedGraph_h
44 #include "vtkCommonDataModelModule.h"
313 {
return this->AddChild(parent,
nullptr); }
An editable directed graph.
void LazyAddVertex(const vtkVariant &pedigreeId)
Adds a vertex with the given pedigreeID to the graph.
vtkEdgeType AddEdge(vtkIdType u, vtkIdType v)
Adds a directed edge from u to v, where u and v are vertex indices, and returns a vtkEdgeType structu...
vtkEdgeType AddEdge(const vtkVariant &u, const vtkVariant &v, vtkVariantArray *propertyArr=nullptr)
Adds a directed edge from u to v, where u and v are vertex pedigree IDs, and returns a vtkEdgeType st...
void LazyAddEdge(vtkIdType u, vtkIdType v, vtkVariantArray *propertyArr=nullptr)
Adds a directed edge from u to v, where u and v are vertex indices.
~vtkMutableDirectedGraph() override
virtual vtkIdType SetNumberOfVertices(vtkIdType numVerts)
Allocates space for the specified number of vertices in the graph's internal data structures.
void RemoveVertices(vtkIdTypeArray *arr)
Removes a collection of vertices from the graph along with any connected edges.
An array holding vtkVariants.
void RemoveEdges(vtkIdTypeArray *arr)
Removes a collection of edges from the graph.
void LazyAddVertex()
Adds a vertex to the graph.
vtkEdgeType AddEdge(const vtkVariant &u, vtkIdType v, vtkVariantArray *propertyArr=nullptr)
Adds a directed edge from u to v, where u is a vertex pedigree ID and v is a vertex index,...
Representation of a single graph edge.
vtkMutableDirectedGraph()
vtkIdType AddChild(vtkIdType parent, vtkVariantArray *propertyArr)
Convenience method for creating trees.
a simple class to control print indentation
A atomic type representing the union of many types.
void LazyAddEdge(const vtkVariant &u, vtkIdType v, vtkVariantArray *propertyArr=nullptr)
Adds a directed edge from u to v, where u is a vertex pedigree ID and v is a vertex index.
Iterates through all edges in a graph.
void LazyAddEdge(vtkIdType u, const vtkVariant &v, vtkVariantArray *propertyArr=nullptr)
Adds a directed edge from u to v, where u is a vertex index and v is a vertex pedigree ID.
vtkIdType AddVertex(const vtkVariant &pedigreeId)
Adds a vertex with the given pedigreeID to the graph and returns the index of the new vertex.
vtkEdgeType AddEdge(vtkIdType u, const vtkVariant &v, vtkVariantArray *propertyArr=nullptr)
Adds a directed edge from u to v, where u is a vertex index and v is a vertex pedigree ID,...
dynamic, self-adjusting array of vtkIdType
void RemoveEdge(vtkIdType e)
Removes the edge from the graph.
vtkIdType AddChild(vtkIdType parent)
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkGraphEdge * GraphEdge
Graph edge that is reused of AddGraphEdge calls.
void LazyAddEdge(const vtkVariant &u, const vtkVariant &v, vtkVariantArray *propertyArr=nullptr)
Adds a directed edge from u to v, where u and v are vertex pedigree IDs.
vtkGraphEdge * AddGraphEdge(vtkIdType u, vtkIdType v)
Variant of AddEdge() that returns a heavyweight vtkGraphEdge object.
void LazyAddVertex(vtkVariantArray *propertyArr)
Adds a vertex to the graph with associated properties defined in propertyArr.
vtkEdgeType AddEdge(vtkIdType u, vtkIdType v, vtkVariantArray *propertyArr)
Adds a directed edge from u to v, where u and v are vertex indices, with associated properties define...
vtkIdType AddVertex()
Adds a vertex to the graph and returns the index of the new vertex.
static vtkMutableDirectedGraph * New()
void RemoveVertex(vtkIdType v)
Removes the vertex from the graph along with any connected edges.
vtkIdType AddVertex(vtkVariantArray *propertyArr)
Adds a vertex to the graph with associated properties defined in propertyArr and returns the index of...