Struct gapi_grpc::google::maps::routes::v1::Route[][src]

pub struct Route {
    pub legs: Vec<RouteLeg>,
    pub distance_meters: i32,
    pub duration: Option<Duration>,
    pub static_duration: Option<Duration>,
    pub polyline: Option<Polyline>,
    pub description: String,
    pub warnings: Vec<String>,
    pub viewport: Option<Viewport>,
    pub travel_advisory: Option<RouteTravelAdvisory>,
}
[]

Encapsulates a route, which consists of a series of connected road segments that join beginning, ending, and intermediate waypoints.

Fields

legs: Vec<RouteLeg>
[]

A collection of legs (path segments between waypoints) that make-up the route. Each leg corresponds to the trip between two non-via Waypoints. For example, a route with no intermediate waypoints has only one leg. A route that includes one non-via intermediate waypoint has two legs. A route that includes one via intermediate waypoint has one leg. The order of the legs matches the order of Waypoints from origin to intermediates to destination.

distance_meters: i32
[]

The travel distance of the route, in meters.

duration: Option<Duration>
[]

The length of time needed to navigate the route. If you set the route_preference to TRAFFIC_UNAWARE, then this value is the same as static_duration. If you set the route_preference to either TRAFFIC_AWARE or TRAFFIC_AWARE_OPTIMAL, then this value is calculated taking traffic conditions into account.

static_duration: Option<Duration>
[]

The duration of traveling through the route without taking traffic conditions into consideration.

polyline: Option<Polyline>
[]

The overall route polyline. This polyline will be the combined polyline of all legs.

description: String
[]

A description of the route.

warnings: Vec<String>
[]

An array of warnings to show when displaying the route.

viewport: Option<Viewport>
[]

The viewport bounding box of the polyline.

travel_advisory: Option<RouteTravelAdvisory>
[]

Additional information about the route.

Trait Implementations

impl Clone for Route[src][+]

impl Debug for Route[src][+]

impl Default for Route[src][+]

impl Message for Route[src][+]

impl PartialEq<Route> for Route[src][+]

impl StructuralPartialEq for Route[src]

Auto Trait Implementations

impl RefUnwindSafe for Route

impl Send for Route

impl Sync for Route

impl Unpin for Route

impl UnwindSafe for Route

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src][+]

impl<T> Borrow<T> for T where
    T: ?Sized
[src][+]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src][+]

impl<T> From<T> for T[src][+]

impl<T> Instrument for T[src][+]

impl<T> Instrument for T[src][+]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src][+]

impl<T> IntoRequest<T> for T[src][+]

impl<T> ToOwned for T where
    T: Clone
[src][+]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src][+]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src][+]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 
[src][+]

impl<T> WithSubscriber for T[src][+]