Response

Enum Response 

Source
pub enum Response {
    Ok {
        result: PlaceResult,
    },
    ZeroResults,
    InvalidRequest,
    OverQueryLimit,
    RequestDenied {
        error_message: String,
    },
    UnknownError,
}
Expand description

https://developers.google.com/maps/documentation/places/web-service/details#PlacesDetailsStatus

Variants§

§

Ok

OK indicating the API request was successful. Includes PlaceResult in result.

Fields

§

ZeroResults

ZERO_RESULTS indicating that the referenced location, place_id, was valid but no longer refers to a valid result. This may occur if the establishment is no longer in business.

§

InvalidRequest

INVALID_REQUEST indicating the API request was malformed

§

OverQueryLimit

OVER_QUERY_LIMIT indicating any of the following:

  • You have exceeded the QPS limits.
  • Billing has not been enabled on your account.
  • The monthly $200 credit, or a self-imposed usage cap, has been exceeded.
  • The provided method of payment is no longer valid (for example, a credit card has expired).
§

RequestDenied

REQUEST_DENIED indicating that your request was denied, generally because:

  • The request is missing an API key.
  • The key parameter is invalid.

Fields

§error_message: String
§

UnknownError

UNKNOWN_ERROR indicating an unknown error

Trait Implementations§

Source§

impl Debug for Response

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for Response

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,