pub struct PlaceProperties {
pub accuracy: Option<Value>,
pub altitude: Option<Value>,
pub latitude: Option<Value>,
pub longitude: Option<Value>,
pub radius: Option<Value>,
pub units: Option<Value>,
}Expand description
Define all the properties of the Location type as described by the Activity Streams vocabulary.
Fields§
§accuracy: Option<Value>Indicates the accuracy of position coordinates on a Place objects.
Expressed in properties of percentage. e.g. “94.0” means “94.0% accurate”.
- Range:
xsd:float[>= 0.0f, <= 100.0f] - Functional: true
altitude: Option<Value>Indicates the altitude of a place. The measurement units is indicated using the units property.
If units is not specified, the default is assumed to be “m” indicating meters.
- Range:
xsd:float - Functional: true
latitude: Option<Value>The latitude of a place.
- Range:
xsd:float - Functional: true
longitude: Option<Value>The longitude of a place.
- Range:
xsd:float - Functional: true
radius: Option<Value>The radius from the given latitude and longitude for a Place.
The units is expressed by the units property. If units is not specified, the default is assumed to be “m” indicating “meters”.
- Range:
xsd:float - Functional: true
units: Option<Value>Specifies the measurement units for the radius and altitude properties on a Place object.
If not specified, the default is assumed to be “m” for “meters”.
- Range:
xsd:float - Functional: true
Implementations§
Source§impl PlaceProperties
impl PlaceProperties
Sourcepub fn accuracy_f64(&self) -> Result<f64>
pub fn accuracy_f64(&self) -> Result<f64>
Retrieve a value from the given struct
This method deserializes the item from JSON, so be wary of using this a lot.
Possible errors from this method are Error::NotFound and
Error::Deserialize
Sourcepub fn set_accuracy_f64(&mut self, item: f64) -> Result<()>
pub fn set_accuracy_f64(&mut self, item: f64) -> Result<()>
Set a value in the given struct
This method serializes the item to JSON, so be wary of using this a lot.
Possible errors from this method are Error::Serialize
Sourcepub fn altitude_f64(&self) -> Result<f64>
pub fn altitude_f64(&self) -> Result<f64>
Retrieve a value from the given struct
This method deserializes the item from JSON, so be wary of using this a lot.
Possible errors from this method are Error::NotFound and
Error::Deserialize
Sourcepub fn set_altitude_f64(&mut self, item: f64) -> Result<()>
pub fn set_altitude_f64(&mut self, item: f64) -> Result<()>
Set a value in the given struct
This method serializes the item to JSON, so be wary of using this a lot.
Possible errors from this method are Error::Serialize
Sourcepub fn latitude_f64(&self) -> Result<f64>
pub fn latitude_f64(&self) -> Result<f64>
Retrieve a value from the given struct
This method deserializes the item from JSON, so be wary of using this a lot.
Possible errors from this method are Error::NotFound and
Error::Deserialize
Sourcepub fn set_latitude_f64(&mut self, item: f64) -> Result<()>
pub fn set_latitude_f64(&mut self, item: f64) -> Result<()>
Set a value in the given struct
This method serializes the item to JSON, so be wary of using this a lot.
Possible errors from this method are Error::Serialize
Sourcepub fn longitude_f64(&self) -> Result<f64>
pub fn longitude_f64(&self) -> Result<f64>
Retrieve a value from the given struct
This method deserializes the item from JSON, so be wary of using this a lot.
Possible errors from this method are Error::NotFound and
Error::Deserialize
Sourcepub fn set_longitude_f64(&mut self, item: f64) -> Result<()>
pub fn set_longitude_f64(&mut self, item: f64) -> Result<()>
Set a value in the given struct
This method serializes the item to JSON, so be wary of using this a lot.
Possible errors from this method are Error::Serialize
Sourcepub fn radius_f64(&self) -> Result<f64>
pub fn radius_f64(&self) -> Result<f64>
Retrieve a value from the given struct
This method deserializes the item from JSON, so be wary of using this a lot.
Possible errors from this method are Error::NotFound and
Error::Deserialize
Sourcepub fn set_radius_f64(&mut self, item: f64) -> Result<()>
pub fn set_radius_f64(&mut self, item: f64) -> Result<()>
Set a value in the given struct
This method serializes the item to JSON, so be wary of using this a lot.
Possible errors from this method are Error::Serialize
Sourcepub fn units_string(&self) -> Result<String>
pub fn units_string(&self) -> Result<String>
Retrieve a value from the given struct
This method deserializes the item from JSON, so be wary of using this a lot.
Possible errors from this method are Error::NotFound and
Error::Deserialize
Sourcepub fn set_units_string(&mut self, item: String) -> Result<()>
pub fn set_units_string(&mut self, item: String) -> Result<()>
Set a value in the given struct
This method serializes the item to JSON, so be wary of using this a lot.
Possible errors from this method are Error::Serialize
Trait Implementations§
Source§impl Clone for PlaceProperties
impl Clone for PlaceProperties
Source§fn clone(&self) -> PlaceProperties
fn clone(&self) -> PlaceProperties
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more