Enum google_maps::places::error::Error
source · pub enum Error {
GoogleMapsService(Status, Option<String>),
HttpUnsuccessful(String),
InvalidStatusCode(String),
InvalidBusinessStatusCode(String),
InvalidSecondaryHoursType(String),
InvalidFieldCode(String),
InvalidRankByCode(String),
InvalidSortOrderCode(String),
QueryNotBuilt,
Reqwest(Error),
ReqwestMessage(String),
SerdeJson(Error),
}
Expand description
Errors that may be produced by the Google Maps Places API client.
Variants§
GoogleMapsService(Status, Option<String>)
Google Maps Places API server generated an error. See the Status
enum for more information.
HttpUnsuccessful(String)
The HTTP request was unsuccessful.
InvalidStatusCode(String)
API client library attempted to parse a string that contained an invalid
status code. See
google_maps\src\places\place_autocomplete\response\status.rs
for more
information.
InvalidBusinessStatusCode(String)
API client library attempted to parse a string that contained an invalid
business status code. See
google_maps\src\places\business_status.rs
for more information.
InvalidSecondaryHoursType(String)
API client library attempted to parse a string that contained an invalid
secondary hours type code. See
google_maps\src\places\secondary_hours_type.rs
for more information.
InvalidFieldCode(String)
API client library attempted to parse a string that contained an invalid
field type code. See
google_maps\src\places\place_details\field.rs
for more information.
InvalidRankByCode(String)
API client library attempted to parse a string that contained an invalid
rank by order type code. See
google_maps\src\places\place_details\rank_by.rs
for more information.
InvalidSortOrderCode(String)
API client library attempted to parse a string that contained an invalid
sort order type code. See
google_maps\src\places\place_details\sort_order.rs
for more information.
QueryNotBuilt
The query string must be built before the request may be sent to the Google Maps Places API server.
Reqwest(Error)
The dependency library Reqwest generated an error.
ReqwestMessage(String)
The dependency library Reqwest generated an error. The error could
not be passed normally so a String
representation is passed instead.
SerdeJson(Error)
The dependency library Serde JSON generated an error.
Trait Implementations§
source§impl Diagnostic for Error
impl Diagnostic for Error
source§fn code(&self) -> Option<Box<dyn Display + '_>>
fn code(&self) -> Option<Box<dyn Display + '_>>
Diagnostic
. Ideally also globally unique, and documented
in the toplevel crate’s documentation for easy searching. Rust path
format (foo::bar::baz
) is recommended, but more classic codes like
E0123
or enums will work just fine.source§fn url(&self) -> Option<Box<dyn Display + '_>>
fn url(&self) -> Option<Box<dyn Display + '_>>
Diagnostic
.source§fn severity(&self) -> Option<Severity>
fn severity(&self) -> Option<Severity>
ReportHandler
s to change the display format
of this diagnostic. Read moresource§fn help<'a>(&'a self) -> Option<Box<dyn Display + 'a>>
fn help<'a>(&'a self) -> Option<Box<dyn Display + 'a>>
Diagnostic
. Do you have any
advice for the poor soul who’s just run into this issue?source§fn source_code(&self) -> Option<&dyn SourceCode>
fn source_code(&self) -> Option<&dyn SourceCode>
Diagnostic
’s Diagnostic::labels
to.source§fn labels(&self) -> Option<Box<dyn Iterator<Item = LabeledSpan> + '_>>
fn labels(&self) -> Option<Box<dyn Iterator<Item = LabeledSpan> + '_>>
Diagnostic
’s Diagnostic::source_code
Diagnostic
s.