pub struct Crs {
pub authority: Authority,
pub version: String,
pub code: String,
}Expand description
Coordinate Reference System (CRS)
Fields§
§version: String§code: StringImplementations§
Source§impl Crs
impl Crs
pub fn new( authority: Authority, version: impl ToString, code: impl ToString, ) -> Crs
pub fn from_epsg(code: i32) -> Self
pub fn from_srid(code: i32) -> Self
pub fn to_urn(&self) -> String
pub fn to_epsg(&self) -> Option<Crs>
pub fn as_epsg(&self) -> Option<i32>
pub fn as_srid(&self) -> i32
Sourcepub fn as_known_crs(&self) -> String
pub fn as_known_crs(&self) -> String
“AUTHORITY:CODE”, like “EPSG:25832”
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Crs
impl<'de> Deserialize<'de> for Crs
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
impl Eq for Crs
impl StructuralPartialEq for Crs
Auto Trait Implementations§
impl Freeze for Crs
impl RefUnwindSafe for Crs
impl Send for Crs
impl Sync for Crs
impl Unpin for Crs
impl UnwindSafe for Crs
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