GeoUtils

object GeoUtils

Utility class for geographic-related functions.

Functions

Link copied to clipboard
fun getTopoLinkId(geometry: LineString, startIndex: Int, endIndex: Int): Long
fun getTopoLinkId(geometry: MultiPoint, startIndex: Int, endIndex: Int): Long
fun getTopoLinkId(points: List<Point>, startIndex: Int = 0, endIndex: Int = points.size): Long

Provides the unique identifier for the given link. Link is a part of a road between two intersection. The identifier is unique within the current road graph within a reasonable some area. It may be used to identify the link in the road graph.

Link copied to clipboard
fun getWayId(edgeId: Long): Expected<String, Long>

Provides the OSM way id for the given directed edge.

fun getWayId(geometry: LineString, startIndex: Int, endIndex: Int): Expected<String, List<Long>>
fun getWayId(points: List<Point>, startIndex: Int = 0, endIndex: Int = points.size): Expected<String, List<Long>>

Provides the OSM way ids encountered along a polyline span, map-matched to the routing graph.