#[non_exhaustive]pub struct Landmark {
pub relational_description: Option<LocalizedText>,
pub tags: Vec<Tag>,
pub straight_line_distance_meters: f64,
pub travel_distance_meters: f64,
pub landmark: Option<Landmark>,
/* private fields */
}Expand description
Landmarks are used to communicate where the destination is or help with arriving at the destination.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.relational_description: Option<LocalizedText>A human-readable description of how the destination relates to the landmark. For example: “Near the Empire State Building” or “Across from the White House”.
Tags that describe how the landmark can be used in the context of the destination.
straight_line_distance_meters: f64Output only. The straight-line distance from this landmark to the destination in meters.
travel_distance_meters: f64Output only. The road-network distance from this landmark to the destination in meters.
landmark: Option<Landmark>The landmark.
Implementations§
Source§impl Landmark
impl Landmark
Sourcepub fn set_relational_description<T>(self, v: T) -> Selfwhere
T: Into<LocalizedText>,
pub fn set_relational_description<T>(self, v: T) -> Selfwhere
T: Into<LocalizedText>,
Sets the value of relational_description.
§Example
use google_cloud_type::model::LocalizedText;
let x = Landmark::new().set_relational_description(LocalizedText::default()/* use setters */);Sourcepub fn set_or_clear_relational_description<T>(self, v: Option<T>) -> Selfwhere
T: Into<LocalizedText>,
pub fn set_or_clear_relational_description<T>(self, v: Option<T>) -> Selfwhere
T: Into<LocalizedText>,
Sets or clears the value of relational_description.
§Example
use google_cloud_type::model::LocalizedText;
let x = Landmark::new().set_or_clear_relational_description(Some(LocalizedText::default()/* use setters */));
let x = Landmark::new().set_or_clear_relational_description(None::<LocalizedText>);Sourcepub fn set_straight_line_distance_meters<T: Into<f64>>(self, v: T) -> Self
pub fn set_straight_line_distance_meters<T: Into<f64>>(self, v: T) -> Self
Sets the value of straight_line_distance_meters.
§Example
let x = Landmark::new().set_straight_line_distance_meters(42.0);Sourcepub fn set_travel_distance_meters<T: Into<f64>>(self, v: T) -> Self
pub fn set_travel_distance_meters<T: Into<f64>>(self, v: T) -> Self
Sets the value of travel_distance_meters.
§Example
let x = Landmark::new().set_travel_distance_meters(42.0);Sourcepub fn set_landmark<T: Into<Option<Landmark>>>(self, v: T) -> Self
pub fn set_landmark<T: Into<Option<Landmark>>>(self, v: T) -> Self
Sourcepub fn place(&self) -> Option<&Box<PlaceView>>
pub fn place(&self) -> Option<&Box<PlaceView>>
The value of landmark
if it holds a Place, None if the field is not set or
holds a different branch.