Enum google_maps::places::place_details::field::Field
source · #[non_exhaustive]#[repr(u8)]pub enum Field {
Show 40 variants
AddressComponent = 0,
AdrAddress = 1,
BusinessStatus = 2,
FormattedAddress = 3,
Geometry = 4,
Icon = 5,
IconMaskBaseUri = 6,
IconBackgroundColor = 8,
Name = 9,
Photo = 10,
PlaceId = 11,
PlusCode = 12,
Type = 13,
Url = 14,
UtcOffset = 15,
Vicinity = 16,
WheelchairAccessibleEntrance = 17,
CurrentOpeningHours = 18,
FormattedPhoneNumber = 19,
InternationalPhoneNumber = 20,
OpeningHours = 21,
SecondaryOpeningHours = 22,
Website = 23,
CurbsidePickup = 24,
Delivery = 25,
DineIn = 26,
EditorialSummary = 27,
PriceLevel = 28,
Rating = 29,
Reservable = 30,
Reviews = 31,
ServesBeer = 32,
ServesBreakfast = 33,
ServesBrunch = 34,
ServesLunch = 35,
ServesVegetarianFood = 36,
ServesWine = 37,
Takeout = 38,
UserRatingsTotal = 39,
Other(String),
}
Expand description
Use the fields parameter to specify a comma-separated list of place data
types to return. For example: fields=formatted_address,name,geometry
. Use
a forward slash when specifying compound values. For example:
opening_hours/open_now
.
Fields are divided into three billing categories: Basic, Contact, and
Atmosphere. Basic fields are billed at base rate, and incur no additional
charges. Contact and Atmosphere fields are billed at a higher rate. See the
pricing sheet for
more information. Attributions, html_attributions
, are always returned
with every call, regardless of whether the field has been requested.
- Caution: Place Search requests and Place Details requests do not return
the same fields. Place Search requests return a subset of the fields that
are returned by Place Details requests. If the field you want is not
returned by Place Search, you can use Place Search to get a
place_id
, then use that Place ID to make a Place Details request. For more information on the fields that are unavailable in a Place Search request, see Places API fields support.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
AddressComponent = 0
AdrAddress = 1
BusinessStatus = 2
FormattedAddress = 3
Geometry = 4
Icon = 5
IconMaskBaseUri = 6
IconBackgroundColor = 8
Name = 9
Photo = 10
PlaceId = 11
PlusCode = 12
Type = 13
Url = 14
UtcOffset = 15
Vicinity = 16
WheelchairAccessibleEntrance = 17
CurrentOpeningHours = 18
FormattedPhoneNumber = 19
InternationalPhoneNumber = 20
OpeningHours = 21
SecondaryOpeningHours = 22
Website = 23
CurbsidePickup = 24
Delivery = 25
DineIn = 26
EditorialSummary = 27
PriceLevel = 28
Rating = 29
Reservable = 30
Reviews = 31
ServesBeer = 32
ServesBreakfast = 33
ServesBrunch = 34
ServesLunch = 35
ServesVegetarianFood = 36
ServesWine = 37
Takeout = 38
UserRatingsTotal = 39
Other(String)
If the field is not recognized by
serde when reading data from
Google it will be assigned to this Other
variant.
As new types are added to Google Maps, they must also be added to this
crate. However, in the meantime, the Other
catch-all variant allows
serde
to read data from Google without producing an error until the
new variant added to this enum
.
Implementations§
Trait Implementations§
source§impl<'de> Deserialize<'de> for Field
impl<'de> Deserialize<'de> for Field
source§fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
fn deserialize<D: Deserializer<'de>>(deserializer: D) -> Result<Self, D::Error>
Manual implementation of Deserialize
for serde
. This will take
advantage of the phf
-powered TryFrom
implementation for this type.
source§impl Ord for Field
impl Ord for Field
source§impl PartialEq for Field
impl PartialEq for Field
source§impl PartialOrd for Field
impl PartialOrd for Field
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read more