Route
data class Route( val id: String, val length: Distance, val travelTime: Duration, val trafficDelay: Duration = Duration.ZERO, val trafficLength: Distance = Distance.ZERO, val departureTimeWithZone: DateTime, val arrivalTimeWithZone: DateTime, val legs: List<RouteLeg>, val routePoints: List<RoutePoint>, val sections: Sections, val batteryConsumptionInkWh: Float = 0.0f, val fuelConsumptionInLiters: Float = 0.0f, val routeCoordinates: List<RouteCoordinate> = emptyList())
Content copied to clipboard
The route class contains the route to be navigated, including geometry and generated guidance messages.
Parameters
id
Unique ID.
length
Route length in meters.
travelTime
Estimated travel time.
trafficDelay
Traffic delay.
trafficLength
Traffic length.
departureTimeWithZone
Estimated departure time including time zone.
arrivalTimeWithZone
Estimated arrival time including time zone.
legs
List of route legs.
routePoints
List containing every waypoint along the route, including origin and destination.
sections
Information about sections of the route.
batteryConsumptionInkWh
Battery consumption for the electric cars.
fuelConsumptionInLiters
Fuels consumption for the regular cars.
routeCoordinates
Optional extended representation of the route.
Important: This is a Public Preview API. It may be changed or removed at any time.
Constructors
Link copied to clipboard
fun Route( id: String, length: Distance, travelTime: Duration, trafficDelay: Duration = Duration.ZERO, trafficLength: Distance = Distance.ZERO, departureTimeWithZone: DateTime, arrivalTimeWithZone: DateTime, legs: List<RouteLeg>, routePoints: List<RoutePoint>, sections: Sections, batteryConsumptionInkWh: Float = 0.0f, fuelConsumptionInLiters: Float = 0.0f, routeCoordinates: List<RouteCoordinate> = emptyList())
Content copied to clipboard
Properties
Link copied to clipboard
Link copied to clipboard
Returns all GeoCoordinates of this route.
Link copied to clipboard