pub struct PlusCode {
pub global_code: String,
pub compound_code: Option<String>,
}
Expand description
(See Open Location Code and plus codes) is an encoded location reference, derived from latitude and longitude coordinates, that represents an area: 1/8000th of a degree by 1/8000th of a degree (about 14m x 14m at the equator) or smaller. Plus codes can be used as a replacement for street addresses in places where they do not exist (where buildings are not numbered or streets are not named).
Typically, both the global code and compound code are returned. However, if the result is in a remote location (for example, an ocean or desert) only the global code may be returned.
Fields§
§global_code: String
A 4 character area code and 6 character or longer local code
(849VCWC8+R9
).
compound_code: Option<String>
A 6 character or longer local code with an explicit location (CWC8+R9, Mountain View, CA, USA
).
Trait Implementations§
source§impl<'de> Deserialize<'de> for PlusCode
impl<'de> Deserialize<'de> for PlusCode
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Ord for PlusCode
impl Ord for PlusCode
source§impl PartialEq for PlusCode
impl PartialEq for PlusCode
source§impl PartialOrd for PlusCode
impl PartialOrd for PlusCode
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Eq for PlusCode
impl StructuralPartialEq for PlusCode
Auto Trait Implementations§
impl Freeze for PlusCode
impl RefUnwindSafe for PlusCode
impl Send for PlusCode
impl Sync for PlusCode
impl Unpin for PlusCode
impl UnwindSafe for PlusCode
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more