Struct activitystreams_types::object::properties::PlaceProperties [−][src]
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>,
}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
Methods
impl PlaceProperties[src]
impl PlacePropertiespub fn accuracy_f64(&self) -> Result<f64>[src]
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
pub fn set_accuracy_f64(&mut self, item: f64) -> Result<()>[src]
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
pub fn altitude_f64(&self) -> Result<f64>[src]
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
pub fn set_altitude_f64(&mut self, item: f64) -> Result<()>[src]
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
pub fn latitude_f64(&self) -> Result<f64>[src]
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
pub fn set_latitude_f64(&mut self, item: f64) -> Result<()>[src]
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
pub fn longitude_f64(&self) -> Result<f64>[src]
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
pub fn set_longitude_f64(&mut self, item: f64) -> Result<()>[src]
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
pub fn radius_f64(&self) -> Result<f64>[src]
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
pub fn set_radius_f64(&mut self, item: f64) -> Result<()>[src]
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
pub fn units_string(&self) -> Result<String>[src]
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
pub fn set_units_string(&mut self, item: String) -> Result<()>[src]
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
impl Clone for PlaceProperties[src]
impl Clone for PlacePropertiesfn clone(&self) -> PlaceProperties[src]
fn clone(&self) -> PlacePropertiesReturns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)Performs copy-assignment from source. Read more
impl Debug for PlaceProperties[src]
impl Debug for PlacePropertiesfn fmt(&self, f: &mut Formatter) -> Result[src]
fn fmt(&self, f: &mut Formatter) -> ResultFormats the value using the given formatter. Read more
impl Default for PlaceProperties[src]
impl Default for PlacePropertiesfn default() -> PlaceProperties[src]
fn default() -> PlacePropertiesReturns the "default value" for a type. Read more
Auto Trait Implementations
impl Send for PlaceProperties
impl Send for PlacePropertiesimpl Sync for PlaceProperties
impl Sync for PlaceProperties