Table of Contents

Class NetworkPathGeometry

Namespace
SpatialNET.Network.Building
Assembly
SpatialNET.Network.Building.dll

Draws the ways of a network on the map from the source lines of their edges (ADR 0050).

public static class NetworkPathGeometry

Inheritance

Inherited Members

Methods

ToPolyline<TNodeId, TEdgeId>(NetworkPath<TNodeId, TEdgeId>, Func<TEdgeId, EdgeShape>, IGeometryFactory?)

The way as one polyline: the piece of the source line of every step, cut with Substring, turned round where the step walks the edge against its direction, and joined.

public static IPolyline2D ToPolyline<TNodeId, TEdgeId>(this NetworkPath<TNodeId, TEdgeId> path, Func<TEdgeId, EdgeShape> shapeOf, IGeometryFactory? factory = null) where TNodeId : notnull, IEquatable<TNodeId> where TEdgeId : notnull, IEquatable<TEdgeId>

Parameters

path NetworkPath<TNodeId, TEdgeId>

The way.

shapeOf Func<TEdgeId, EdgeShape>

The source line and range of an edge, from the host (for example InMemoryGraph.TryGetSource or its database).

factory IGeometryFactory?

The factory; null = SpatialNET.GeometryFactory.Default.

Returns

IPolyline2D

The way; an empty polyline for a way without steps.

Type Parameters

TNodeId
TEdgeId

Exceptions

ArgumentNullException

path or shapeOf is null, or a shape has no line.

InvalidOperationException

No factory available.