Interface INode<TEdge, TNode>
Represents the node/vertex contract for the ISpatialGraphEnvironment which handle incoming
and outgoing edges.
Namespace: Mars.Interfaces.Environments
Assembly: Mars.Interfaces.dll
Syntax
public interface INode<TEdge, TNode> : IGraphEntity, IEqualityComparer<IGraphEntity> where TEdge : IEdge<TEdge, TNode> where TNode : INode<TEdge, TNode>
Type Parameters
Name | Description |
---|---|
TEdge | |
TNode |
Properties
IncomingEdges
Gets the collection of all incoming edges,
targeting into this node.
Declaration
IDictionary<int, TEdge> IncomingEdges { get; }
Property Value
Type | Description |
---|---|
IDictionary<System.Int32, TEdge> |
OutgoingEdges
Gets all outgoing or adjacent edges of this node.
For simple graphs, the IncomingEdges as well as the OutgoingEdges
has an entry with the same edge.
Declaration
IDictionary<int, TEdge> OutgoingEdges { get; }
Property Value
Type | Description |
---|---|
IDictionary<System.Int32, TEdge> |
Methods
AddIncomingEdge(TEdge)
Adds an edge to the incoming set of this node.
Declaration
void AddIncomingEdge(TEdge edge)
Parameters
Type | Name | Description |
---|---|---|
TEdge | edge | The edge to add with incoming direction. |
AddOutgoingEdge(TEdge)
Adds an edge to the outgoing set of this node.
Declaration
void AddOutgoingEdge(TEdge edge)
Parameters
Type | Name | Description |
---|---|---|
TEdge | edge | The edge to add with outgoing direction. |