Show / Hide Table of Contents

Interface IHierarchy<TVertex, TEdge>

Represents a hierarchy of graphs.

Inherited Members
IMutableIncidenceGraph<TVertex, TEdge>.RemoveOutEdgeIf(TVertex, EdgePredicate<TVertex, TEdge>)
IMutableIncidenceGraph<TVertex, TEdge>.ClearOutEdges(TVertex)
IMutableIncidenceGraph<TVertex, TEdge>.TrimEdgeExcess()
IMutableVertexAndEdgeSet<TVertex, TEdge>.AddVerticesAndEdge(TEdge)
IMutableVertexAndEdgeSet<TVertex, TEdge>.AddVerticesAndEdgeRange(IEnumerable<TEdge>)
IMutableVertexSet<TVertex>.VertexAdded
IMutableVertexSet<TVertex>.AddVertex(TVertex)
IMutableVertexSet<TVertex>.AddVertexRange(IEnumerable<TVertex>)
IMutableVertexSet<TVertex>.VertexRemoved
IMutableVertexSet<TVertex>.RemoveVertex(TVertex)
IMutableVertexSet<TVertex>.RemoveVertexIf(VertexPredicate<TVertex>)
IMutableEdgeListGraph<TVertex, TEdge>.AddEdge(TEdge)
IMutableEdgeListGraph<TVertex, TEdge>.EdgeAdded
IMutableEdgeListGraph<TVertex, TEdge>.AddEdgeRange(IEnumerable<TEdge>)
IMutableEdgeListGraph<TVertex, TEdge>.RemoveEdge(TEdge)
IMutableEdgeListGraph<TVertex, TEdge>.EdgeRemoved
IMutableEdgeListGraph<TVertex, TEdge>.RemoveEdgeIf(EdgePredicate<TVertex, TEdge>)
IMutableGraph<TVertex, TEdge>.Clear()
IIncidenceGraph<TVertex, TEdge>.ContainsEdge(TVertex, TVertex)
IIncidenceGraph<TVertex, TEdge>.TryGetEdge(TVertex, TVertex, TEdge)
IIncidenceGraph<TVertex, TEdge>.TryGetEdges(TVertex, TVertex, IEnumerable<TEdge>)
IImplicitGraph<TVertex, TEdge>.IsOutEdgesEmpty(TVertex)
IImplicitGraph<TVertex, TEdge>.OutDegree(TVertex)
IImplicitGraph<TVertex, TEdge>.OutEdges(TVertex)
IImplicitGraph<TVertex, TEdge>.TryGetOutEdges(TVertex, IEnumerable<TEdge>)
IImplicitGraph<TVertex, TEdge>.OutEdge(TVertex, Int32)
IGraph<TVertex, TEdge>.IsDirected
IGraph<TVertex, TEdge>.AllowParallelEdges
IEdgeSet<TVertex, TEdge>.IsEdgesEmpty
IEdgeSet<TVertex, TEdge>.EdgeCount
IEdgeSet<TVertex, TEdge>.Edges
IEdgeSet<TVertex, TEdge>.ContainsEdge(TEdge)
IVertexSet<TVertex>.IsVerticesEmpty
IVertexSet<TVertex>.VertexCount
IVertexSet<TVertex>.Vertices
IImplicitVertexSet<TVertex>.ContainsVertex(TVertex)
Namespace: QuikGraph
Assembly: QuikGraph.dll
Syntax
public interface IHierarchy<TVertex, TEdge> : IMutableVertexAndEdgeListGraph<TVertex, TEdge>, IMutableVertexListGraph<TVertex, TEdge>, IMutableIncidenceGraph<TVertex, TEdge>, IMutableVertexAndEdgeSet<TVertex, TEdge>, IMutableVertexSet<TVertex>, IMutableEdgeListGraph<TVertex, TEdge>, IMutableGraph<TVertex, TEdge>, IVertexAndEdgeListGraph<TVertex, TEdge>, IVertexListGraph<TVertex, TEdge>, IIncidenceGraph<TVertex, TEdge>, IImplicitGraph<TVertex, TEdge>, IEdgeListGraph<TVertex, TEdge>, IGraph<TVertex, TEdge>, IEdgeSet<TVertex, TEdge>, IVertexSet<TVertex>, IImplicitVertexSet<TVertex> where TEdge : IEdge<TVertex>
Type Parameters
Name Description
TVertex

Vertex type.

TEdge

Edge type.

Properties

| Improve this Doc View Source

Root

Gets the root of the hierarchy.

Declaration
TVertex Root { get; }
Property Value
Type Description
TVertex

Methods

| Improve this Doc View Source

ChildrenEdges(TVertex)

Gets the collection of children edges from the vertex.

Declaration
IEnumerable<TEdge> ChildrenEdges(TVertex vertex)
Parameters
Type Name Description
TVertex vertex

The vertex.

Returns
Type Description
System.Collections.Generic.IEnumerable<TEdge>

Children edges.

Exceptions
Type Condition
System.ArgumentNullException

vertex is null.

| Improve this Doc View Source

ChildrenVertices(TVertex)

Gets the collection of children vertices from the vertex.

Declaration
IEnumerable<TVertex> ChildrenVertices(TVertex vertex)
Parameters
Type Name Description
TVertex vertex

The vertex.

Returns
Type Description
System.Collections.Generic.IEnumerable<TVertex>

Children vertices.

Exceptions
Type Condition
System.ArgumentNullException

vertex is null.

| Improve this Doc View Source

GetParent(TVertex)

Gets the parent vertex of the given vertex.

Declaration
TVertex GetParent(TVertex vertex)
Parameters
Type Name Description
TVertex vertex

The vertex.

Returns
Type Description
TVertex

The parent vertex if there is one, otherwise null.

Exceptions
Type Condition
System.ArgumentNullException

vertex is null.

System.ArgumentException

The given vertex is the root of the graph.

| Improve this Doc View Source

GetParentEdge(TVertex)

Gets the parent edge of the vertex.

Declaration
TEdge GetParentEdge(TVertex vertex)
Parameters
Type Name Description
TVertex vertex

The vertex.

Returns
Type Description
TEdge

The parent vertex edge.

Exceptions
Type Condition
System.ArgumentNullException

vertex is null.

System.ArgumentException

The given vertex is the root of the graph.

| Improve this Doc View Source

InducedEdgeCount(TVertex, TVertex)

Gets the number of edges between the source and target vertex.

Declaration
int InducedEdgeCount(TVertex source, TVertex target)
Parameters
Type Name Description
TVertex source

Source vertex.

TVertex target

Target vertex.

Returns
Type Description
System.Int32

The number of edge between source and target.

Exceptions
Type Condition
System.ArgumentNullException

source is null.

System.ArgumentNullException

target is null.

System.ArgumentException

The source is a predecessor of target or the other-way round.

| Improve this Doc View Source

IsCrossEdge(TEdge)

Gets a value indicating if edge is a cross edge.

Declaration
bool IsCrossEdge(TEdge edge)
Parameters
Type Name Description
TEdge edge

The edge.

Returns
Type Description
System.Boolean

True if the edge is a cross edge, false otherwise.

Exceptions
Type Condition
System.ArgumentNullException

edge is null.

| Improve this Doc View Source

IsInnerNode(TVertex)

Gets a value indicating if the vertex is an inner node or a leaf.

Declaration
bool IsInnerNode(TVertex vertex)
Parameters
Type Name Description
TVertex vertex

The vertex.

Returns
Type Description
System.Boolean

True if the vertex is not a leaf, false otherwise.

Exceptions
Type Condition
System.ArgumentNullException

vertex is null.

| Improve this Doc View Source

IsPredecessorOf(TVertex, TVertex)

Gets a value indicating if source is a predecessor of target.

Declaration
bool IsPredecessorOf(TVertex source, TVertex target)
Parameters
Type Name Description
TVertex source

Source vertex.

TVertex target

Target vertex.

Returns
Type Description
System.Boolean

True if the source is a predecessor of target.

Exceptions
Type Condition
System.ArgumentNullException

source is null.

System.ArgumentNullException

target is null.

| Improve this Doc View Source

IsRealEdge(TEdge)

Gets a value indicating whether the edge exists really or is just an induced edge.

Declaration
bool IsRealEdge(TEdge edge)
Parameters
Type Name Description
TEdge edge

The edge.

Returns
Type Description
System.Boolean

True if it's a real edge, false otherwise.

Exceptions
Type Condition
System.ArgumentNullException

edge is null.

Extension Methods

DirectedGraphMLExtensions.ToDirectedGraphML<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>)
DirectedGraphMLExtensions.ToDirectedGraphML<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>, Func<TVertex, GraphColor>)
DirectedGraphMLExtensions.ToDirectedGraphML<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>, VertexIdentity<TVertex>, EdgeIdentity<TVertex, TEdge>)
DirectedGraphMLExtensions.ToDirectedGraphML<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>, VertexIdentity<TVertex>, EdgeIdentity<TVertex, TEdge>, Action<TVertex, DirectedGraphNode>, Action<TEdge, DirectedGraphLink>)
DirectedGraphMLExtensions.OpenAsDGML<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>, String)
GraphMLExtensions.SerializeToGraphML<TVertex, TEdge, TGraph>(TGraph, String)
GraphMLExtensions.SerializeToGraphML<TVertex, TEdge, TGraph>(TGraph, String, VertexIdentity<TVertex>, EdgeIdentity<TVertex, TEdge>)
GraphMLExtensions.SerializeToGraphML<TVertex, TEdge, TGraph>(TGraph, XmlWriter)
GraphMLExtensions.SerializeToGraphML<TVertex, TEdge, TGraph>(TGraph, XmlWriter, VertexIdentity<TVertex>, EdgeIdentity<TVertex, TEdge>)
GraphMLExtensions.DeserializeFromGraphML<TVertex, TEdge, TGraph>(TGraph, XmlReader, IdentifiableVertexFactory<TVertex>, IdentifiableEdgeFactory<TVertex, TEdge>)
GraphMLExtensions.DeserializeFromGraphML<TVertex, TEdge, TGraph>(TGraph, TextReader, IdentifiableVertexFactory<TVertex>, IdentifiableEdgeFactory<TVertex, TEdge>)
GraphMLExtensions.DeserializeFromGraphML<TVertex, TEdge, TGraph>(TGraph, String, IdentifiableVertexFactory<TVertex>, IdentifiableEdgeFactory<TVertex, TEdge>)
GraphMLExtensions.DeserializeAndValidateFromGraphML<TVertex, TEdge, TGraph>(TGraph, TextReader, IdentifiableVertexFactory<TVertex>, IdentifiableEdgeFactory<TVertex, TEdge>)
SerializationExtensions.SerializeToBinary<TVertex, TEdge>(IGraph<TVertex, TEdge>, Stream)
SerializationExtensions.SerializeToXml<TVertex, TEdge, TGraph>(TGraph, XmlWriter, VertexIdentity<TVertex>, EdgeIdentity<TVertex, TEdge>, String, String, String, String)
SerializationExtensions.SerializeToXml<TVertex, TEdge, TGraph>(TGraph, XmlWriter, VertexIdentity<TVertex>, EdgeIdentity<TVertex, TEdge>, String, String, String, String, Action<XmlWriter, TGraph>, Action<XmlWriter, TVertex>, Action<XmlWriter, TEdge>)
GraphExtensions.ToArrayAdjacencyGraph<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>)
GraphExtensions.ToBidirectionalGraph<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>)
GraphExtensions.ToCompressedRowGraph<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>)
AlgorithmExtensions.GetVertexIdentity<TVertex>(IVertexSet<TVertex>)
AlgorithmExtensions.GetEdgeIdentity<TVertex, TEdge>(IEdgeSet<TVertex, TEdge>)
AlgorithmExtensions.TreeBreadthFirstSearch<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>, TVertex)
AlgorithmExtensions.TreeDepthFirstSearch<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>, TVertex)
AlgorithmExtensions.TreeCyclePoppingRandom<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>, TVertex)
AlgorithmExtensions.TreeCyclePoppingRandom<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>, TVertex, IMarkovEdgeChain<TVertex, TEdge>)
AlgorithmExtensions.ShortestPathsDijkstra<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>, Func<TEdge, Double>, TVertex)
AlgorithmExtensions.ShortestPathsAStar<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>, Func<TEdge, Double>, Func<TVertex, Double>, TVertex)
AlgorithmExtensions.ShortestPathsBellmanFord<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>, Func<TEdge, Double>, TVertex, out Boolean)
AlgorithmExtensions.ShortestPathsDag<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>, Func<TEdge, Double>, TVertex)
AlgorithmExtensions.Sinks<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>)
AlgorithmExtensions.Roots<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>)
AlgorithmExtensions.TopologicalSort<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>)
AlgorithmExtensions.SourceFirstTopologicalSort<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>)
AlgorithmExtensions.IncrementalConnectedComponents<TVertex, TEdge>(IMutableVertexAndEdgeSet<TVertex, TEdge>, out Func<KeyValuePair<Int32, IDictionary<TVertex, Int32>>>)
AlgorithmExtensions.StronglyConnectedComponents<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>, IDictionary<TVertex, Int32>)
AlgorithmExtensions.WeaklyConnectedComponents<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>, IDictionary<TVertex, Int32>)
AlgorithmExtensions.CondensateStronglyConnected<TVertex, TEdge, TGraph>(IVertexAndEdgeListGraph<TVertex, TEdge>)
AlgorithmExtensions.CondensateWeaklyConnected<TVertex, TEdge, TGraph>(IVertexAndEdgeListGraph<TVertex, TEdge>)
AlgorithmExtensions.OddVertices<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>)
AlgorithmExtensions.IsDirectedAcyclicGraph<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>)
AlgorithmExtensions.OfflineLeastCommonAncestor<TVertex, TEdge>(IVertexListGraph<TVertex, TEdge>, TVertex, IEnumerable<SEquatableEdge<TVertex>>)
AlgorithmExtensions.MaximumFlow<TVertex, TEdge>(IMutableVertexAndEdgeListGraph<TVertex, TEdge>, Func<TEdge, Double>, TVertex, TVertex, out TryFunc<TVertex, TEdge>, EdgeFactory<TVertex, TEdge>, ReversedEdgeAugmentorAlgorithm<TVertex, TEdge>)
AlgorithmExtensions.ComputeTransitiveReduction<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>)
AlgorithmExtensions.ComputeTransitiveClosure<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>, Func<TVertex, TVertex, TEdge>)
AlgorithmExtensions.Clone<TVertex, TEdge>(IVertexAndEdgeListGraph<TVertex, TEdge>, Func<TVertex, TVertex>, Func<TEdge, TVertex, TVertex, TEdge>, IMutableVertexAndEdgeSet<TVertex, TEdge>)
GraphvizExtensions.ToGraphviz<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>)
GraphvizExtensions.ToGraphviz<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>, Action<GraphvizAlgorithm<TVertex, TEdge>>)
GraphvizExtensions.ToSvg<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>)
GraphvizExtensions.ToSvg<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>, Action<GraphvizAlgorithm<TVertex, TEdge>>)
MsaglGraphExtensions.CreateMsaglPopulator<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>)
MsaglGraphExtensions.CreateMsaglPopulator<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>, String, IFormatProvider)
MsaglGraphExtensions.CreateMsaglPopulator<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>, VertexIdentity<TVertex>)
MsaglGraphExtensions.ToMsaglGraph<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>, MsaglVertexNodeEventHandler<TVertex>, MsaglEdgeEventHandler<TVertex, TEdge>)
MsaglGraphExtensions.ToMsaglGraph<TVertex, TEdge>(IEdgeListGraph<TVertex, TEdge>, VertexIdentity<TVertex>, MsaglVertexNodeEventHandler<TVertex>, MsaglEdgeEventHandler<TVertex, TEdge>)
  • Improve this Doc
  • View Source
In This Article
Back to top QuikGraph