Struct GraphEdge<TNodeId, TEdgeId>
- Namespace
- SpatialNET.Network
- Assembly
- SpatialNET.Network.dll
An edge of a network as the host returns it (ADR 0049). Parallel edges and loops are allowed.
public readonly record struct GraphEdge<TNodeId, TEdgeId> : IEquatable<GraphEdge<TNodeId, TEdgeId>> where TNodeId : notnull, IEquatable<TNodeId> where TEdgeId : notnull, IEquatable<TEdgeId>Type Parameters
TNodeId-
The host's node id.
TEdgeId-
The host's edge id.
Implements
Inherited Members
Constructors
GraphEdge(TEdgeId, TNodeId, TNodeId, int, double, EdgeDirection, bool, ReadOnlyMemory<EdgeWeight>)
An edge of a network as the host returns it (ADR 0049). Parallel edges and loops are allowed.
public GraphEdge(TEdgeId Id, TNodeId From, TNodeId To, int TypeId, double Length, EdgeDirection Direction = EdgeDirection.Both, bool Disabled = false, ReadOnlyMemory<EdgeWeight> Weights = default)Parameters
IdTEdgeId-
The id; unique across all feature classes of the host.
FromTNodeId-
The node at the start, in digitizing direction.
ToTNodeId-
The node at the end.
TypeIdint-
The type (see SpatialNET.Network.TypeRegistry).
Lengthdouble-
The length in the units of the coordinates, or a surveyed length.
DirectionEdgeDirection-
The normal direction in which the edge may be walked.
Disabledbool-
The normal switching state: a disabled edge does not exist for a search.
WeightsReadOnlyMemory<EdgeWeight>-
The values of the weights, travelling with the edge so that a search never queries them on their own.
Properties
Direction
The normal direction in which the edge may be walked.
public EdgeDirection Direction { get; init; }Property Value
Disabled
The normal switching state: a disabled edge does not exist for a search.
public bool Disabled { get; init; }Property Value
From
The node at the start, in digitizing direction.
public TNodeId From { get; init; }Property Value
- TNodeId
Id
The id; unique across all feature classes of the host.
public TEdgeId Id { get; init; }Property Value
- TEdgeId
Length
The length in the units of the coordinates, or a surveyed length.
public double Length { get; init; }Property Value
To
The node at the end.
public TNodeId To { get; init; }Property Value
- TNodeId
TypeId
The type (see SpatialNET.Network.TypeRegistry).
public int TypeId { get; init; }Property Value
Weights
The values of the weights, travelling with the edge so that a search never queries them on their own.
public ReadOnlyMemory<EdgeWeight> Weights { get; init; }