pub struct Point<A: Angle> { /* private fields */ }Expand description
The point on the surface of an ellipsoid, represented as the pair (latitude, longitude)
Implementations§
Source§impl<A: Angle> Point<A>
impl<A: Angle> Point<A>
Sourcepub fn new(lat: Latitude<A>, lon: Longitude<A>) -> Self
pub fn new(lat: Latitude<A>, lon: Longitude<A>) -> Self
Construct a point from the given latitude and longitude
Sourcepub fn with_coordinates<Lat, Lon>(lat: Lat, lon: Lon) -> Result<Self, A::NumErr>
pub fn with_coordinates<Lat, Lon>(lat: Lat, lon: Lon) -> Result<Self, A::NumErr>
Construct a point on the surface with some numeric information about latitude and longitude.
§Errors
An overflow of some kind can appear when constructing latitude or longitude from the given numbers.
Sourcepub fn north_pole() -> Self
pub fn north_pole() -> Self
Construct a north pole point (lat=90, lon=0 (by convention)).
Sourcepub fn south_pole() -> Self
pub fn south_pole() -> Self
Construct a south pole point (lat=-90, lon=0 (by convention)).
Trait Implementations§
Auto Trait Implementations§
impl<A> Freeze for Point<A>where
A: Freeze,
impl<A> RefUnwindSafe for Point<A>where
A: RefUnwindSafe,
impl<A> Send for Point<A>where
A: Send,
impl<A> Sync for Point<A>where
A: Sync,
impl<A> Unpin for Point<A>where
A: Unpin,
impl<A> UnwindSafe for Point<A>where
A: UnwindSafe,
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