Table of Contents

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

Id TEdgeId

The id; unique across all feature classes of the host.

From TNodeId

The node at the start, in digitizing direction.

To TNodeId

The node at the end.

TypeId int

The type (see SpatialNET.Network.TypeRegistry).

Length double

The length in the units of the coordinates, or a surveyed length.

Direction EdgeDirection

The normal direction in which the edge may be walked.

Disabled bool

The normal switching state: a disabled edge does not exist for a search.

Weights ReadOnlyMemory<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

EdgeDirection

Disabled

The normal switching state: a disabled edge does not exist for a search.

public bool Disabled { get; init; }

Property Value

bool

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

double

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

int

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; }

Property Value

ReadOnlyMemory<EdgeWeight>