[][src]Enum google_maps::directions::request::transit_route_preference::TransitRoutePreference

pub enum TransitRoutePreference {
    FewerTransfers,
    LessWalking,
}

Specifies preferences for transit routes.

Transit Route Preferences

Using this parameter, you can bias the options returned, rather than accepting the default best route chosen by the API. This parameter may only be specified for transit directions, and only if the request includes an API key or a Google Maps Platform Premium Plan client ID.

Variants

FewerTransfers

Specifies that the calculated route should prefer a limited number of transfers.

LessWalking

Specifies that the calculated route should prefer limited amounts of walking.

Methods

impl TransitRoutePreference[src]

pub fn source_code_print(&self) -> String[src]

Converts a TransitRoutePreference enum to a String that contains a pretty source-code-style transit route preference code for debugging.

Trait Implementations

impl Clone for TransitRoutePreference[src]

impl Debug for TransitRoutePreference[src]

impl<'_> From<&'_ TransitRoutePreference> for String[src]

fn from(transit_route_preference: &TransitRoutePreference) -> String[src]

Converts a TransitRoutePreference enum to a String that contains a transit route preference code.

impl From<String> for TransitRoutePreference[src]

fn from(transit_route_preference: String) -> TransitRoutePreference[src]

Gets a TransitRoutePreference enum from a String that contains a valid transit route preference code.

Auto Trait Implementations

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, U> Into<U> for T where
    U: From<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.