[][src]Enum google_maps::GeocodingError

pub enum GeocodingError {
    AddressOrComponentsRequired,
    GoogleMapsService(StatusOption<String>),
    HttpUnsuccessful(u8String),
    InvalidCountryCode(String),
    InvalidLocationTypeCode(String),
    InvalidStatusCode(String),
    QueryNotBuilt,
    RequestNotValidated,
    Reqwest(Error),
    SerdeJson(Error),
}

Errors that may be produced by the Google Maps Geocoding API client.

Variants

AddressOrComponentsRequired

Forward geocoding requests (address to latlng) must specify an address or at least one component.

GoogleMapsService(StatusOption<String>)

Google Maps Geocoding API server generated an error. See the Status enum for more information.

HttpUnsuccessful(u8String)

The HTTP request was unsuccessful.

InvalidCountryCode(String)

API client library attempted to parse a string that contained an invalid country code. See google_maps\src\geocoding\forward\country.rs for more information.

InvalidLocationTypeCode(String)

API client library attempted to parse a string that contained an invalid location type code. See google_maps\src\geocoding\location_types.rs for more information.

InvalidStatusCode(String)

API client library attempted to parse a string that contained an invalid status code. See google_maps\src\geocoding\response\status.rs for more information.

QueryNotBuilt

The query string must be built before the request may be sent to the Google Maps Geocoding API server.

RequestNotValidated

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.

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 Geocoding API error type into the native error type of the underlying library.

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 Geocoding API error type (google_maps::geocoding::error::Error) by wrapping it inside. This function is required to use the ? operator.

impl From<Error> for Error[src]

fn from(error: Error) -> Error[src]

This trait converts from an Serde JSON (serde_json::error::Error) error type into a Google Maps Geocoding API error type (google_maps::geocoding::error::Error) by wrapping it inside. This function is required to use the ? operator.

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]

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> ToString for T where
    T: Display + ?Sized
[src]

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>,