Route class

Bing
 

Represents a route.

Name

Type

Description

Bounds

LocationRect

Gets the location rectangle that contains the route. This can be used to set the map view for the route.

DistanceUnit

DistanceUnitOption

Gets the distance unit used for distance measurements in the route.

DurationUnit

string

Gets the time unit used for durations in the route.

Id

string

Gets the ID of the route.

RouteLegs

RouteLegCollection

Gets a collection of route legs representing the route. A route leg is the section of a route between two waypoints.

RouteMode

RouteModeOption

Gets the mode of travel for the route.

RoutePath

RoutePath

Gets the route path of the route, if requested.

TravelDistance

double

Gets the total travel distance of the route. This property is not supported for transit routes.

TravelTime

double

Gets the total travel time of the route, in seconds.

Show: