Table of Contents

Interface INode

Namespace
Echo.Graphing
Assembly
Echo.dll

Represents a single node in a generic directed graph.

public interface INode

Properties

InDegree

Gets a value indicating the number of incoming edges that this node is incident to.

int InDegree { get; }

Property Value

int

OutDegree

Gets a value indicating the number of outgoing edges that this node is incident to.

int OutDegree { get; }

Property Value

int

Methods

GetIncomingEdges()

Gets a collection of all edges that target this node.

IEnumerable<IEdge> GetIncomingEdges()

Returns

IEnumerable<IEdge>

The incoming edges.

GetOutgoingEdges()

Gets a collection of all outgoing edges originating from this node.

IEnumerable<IEdge> GetOutgoingEdges()

Returns

IEnumerable<IEdge>

The outgoing edges.

GetPredecessors()

Gets a collection of nodes that precede this node.

IEnumerable<INode> GetPredecessors()

Returns

IEnumerable<INode>

The predecessor nodes.

GetSuccessors()

Gets a collection of nodes that can be reached from this node by following one of the incident edges.

IEnumerable<INode> GetSuccessors()

Returns

IEnumerable<INode>

The successor nodes.

HasPredecessor(INode)

Determines whether the provided node precedes the current node.

bool HasPredecessor(INode node)

Parameters

node INode

The node to check.

Returns

bool

True if the node is a predecessor, false otherwise.

HasSuccessor(INode)

Determines whether the provided node can be reached from this node by following one of the incident edges.

bool HasSuccessor(INode node)

Parameters

node INode

The node to check.

Returns

bool

True if the node is a successor, false otherwise.