[−][src]Enum google_maps::directions::error::Error
Errors that may be produced by the Google Maps Directions API client.
Variants
An arrival time may only be specified in Transit travel mode.
EitherAlternativesOrWaypoints(usize)
Alternatives may not be requested when waypoints are specified.
An departure time may not be specified when an arrival time is specified.
Restrictions may not be specified when waypoints are specified.
EitherWaypointsOrTransitMode(usize)
Waypoints may not be specified in Transit travel mode.
Google Maps Directions API server generated an error. See the Status
enum for more information.
InvalidAvoidCode(String)
API client library attempted to parse a string that contained an invalid
avoid/restrictions code. See
google_maps\src\directions\request\avoid.rs
for more information.
InvalidGeocoderStatusCode(String)
API client library attempted to parse a string that contained an invalid
geocoder status code. See
google_maps\src\directions\response\geocoder_status.rs
for more
information.
InvalidManeuverTypeCode(String)
API client library attempted to parse a string that contained an invalid
maneuver type code. See
google_maps\src\directions\response\maneuver_type.rs
for more
information.
InvalidStatusCode(String)
API client library attempted to parse a string that contained an invalid
status code. See google_maps\src\directions\response\status.rs
for
more information.
InvalidTrafficModelCode(String)
API client library attempted to parse a string that contained an invalid
traffic model code. See
google_maps\src\directions\request\traffic_model.rs
for more
information.
InvalidTransitModeCode(String)
API client library attempted to parse a string that contained an invalid
transit mode code. See
google_maps\src\directions\request\transit_mode.rs
for more
information.
InvalidTransitRoutePreferenceCode(String)
API client library attempted to parse a string that contained an invalid
transit routing preference code. See
google_maps\src\directions\request\transit_route_preference.rs
for
more information.
InvalidTravelModeCode(String)
API client library attempted to parse a string that contained an invalid
travel mode code. See google_maps\src\directions\travel_mode.rs
for
more information.
InvalidUnitSystemCode(String)
API client library attempted to parse a string that contained an invalid
unit system code. See
google_maps\src\directions\request\unit_system.rs
for more
information.
InvalidVehicleTypeCode(String)
API client library attempted to parse a string that contained an invalid
vehicle type code. See google_maps\src\directions\vehicle_type.rs
for
more information.
The query string must be built before the request may be sent to the Google Maps Directions API server.
The request must be validated before a query string may be built.
Reqwest(Error)
The dependency library Reqwest generated an error.
SerdeJson(Error)
The dependency library Serde JSON generated an error.
TooManyWaypoints(usize)
Too many waypoints specified.
Transit mode may only be specified in Transit travel mode.
Transit routing preference may only be specified in Transit travel mode.
Trait Implementations
impl Debug for Error
[src]
impl Display for Error
[src]
fn fmt(&self, f: &mut Formatter) -> Result
[src]
This trait converts the error code into a format that may be presented to the user.
impl Error for Error
[src]
fn source(&self) -> Option<&(dyn Error + 'static)>
[src]
If the cause for the error is in an underlying library (not this library but a library this one depends on), this trait unwraps the original source error. This trait converts a Google Maps Directions API error type into the native error type of the underlying library.
fn backtrace(&self) -> Option<&Backtrace>
[src]
fn description(&self) -> &str
1.0.0[src]
fn cause(&self) -> Option<&dyn Error>
1.0.0[src]
impl From<Error> for Error
[src]
fn from(error: Error) -> Error
[src]
This trait converts from an Reqwest error type (reqwest::Error
) into a
Google Maps Directions API error type
(google_maps::directions::error::Error
) by wrapping it inside. This
function is required to use the ?
operator.
impl From<Error> for Error
[src]
Auto Trait Implementations
impl !RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl !UnwindSafe for Error
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,