Struct geod::Latitude [−][src]
The angle measured between the equatorial plane and the point along the meridian. Read more.
Implementations
impl<A: Angle> Latitude<A>
[src]
pub fn north<T>(angle: T) -> Result<Self, A::NumErr> where
T: TryInto<A, Error = A::NumErr>,
[src]
T: TryInto<A, Error = A::NumErr>,
Construct a northern latitude with some numeric information.
Errors
- cannot construct an angle from the given information (overflow of some kind)
- the constructed angle is more than the right angle.
Valid latitude is in the range
0 <= lat <= 90 deg
.
pub fn south<T>(angle: T) -> Result<Self, A::NumErr> where
T: TryInto<A, Error = A::NumErr>,
[src]
T: TryInto<A, Error = A::NumErr>,
Construct a southern latitude with some numeric information.
Errors
- cannot construct an angle from the given information (overflow of some kind)
- the constructed angle is more than the right angle.
Valid latitude is in the range
0 <= lat <= 90 deg
.
pub fn equator() -> Self
[src]
The central latitude of the sphere equidistant from the poles
pub fn angle_from_equator(self) -> A
[src]
Angle between the latitude and the equator (absolute value of the latitude).
pub fn hemisphere(self) -> Option<Pole>
[src]
Which pole are closer to the given latitude
pub fn is_pole(self) -> bool
[src]
Is the given latitude belongs to a pole
Trait Implementations
impl<A: Angle> Add<A> for Latitude<A>
[src]
type Output = Result<Self, A::NumErr>
The resulting type after applying the +
operator.
fn add(self, rhs: A) -> Self::Output
[src]
Represent the north movement
impl<A: Clone + Angle> Clone for Latitude<A>
[src]
impl<A: Copy + Angle> Copy for Latitude<A>
[src]
impl<A: Debug + Angle> Debug for Latitude<A>
[src]
impl<A: Angle> Default for Latitude<A>
[src]
impl<A: Angle> Display for Latitude<A> where
A: Display,
[src]
A: Display,
impl<A: Eq + Angle> Eq for Latitude<A>
[src]
impl<A: Angle> FromStr for Latitude<A> where
A::ParseErr: From<A::NumErr>,
[src]
A::ParseErr: From<A::NumErr>,
type Err = ParseCoordinateError<A::ParseErr>
The associated error which can be returned from parsing.
fn from_str(s: &str) -> Result<Self, Self::Err>
[src]
impl<A: Angle> Neg for Latitude<A>
[src]
type Output = Self
The resulting type after applying the -
operator.
fn neg(self) -> Self::Output
[src]
impl<A: Ord + Angle> Ord for Latitude<A>
[src]
fn cmp(&self, other: &Latitude<A>) -> Ordering
[src]
#[must_use]pub fn max(self, other: Self) -> Self
1.21.0[src]
#[must_use]pub fn min(self, other: Self) -> Self
1.21.0[src]
#[must_use]pub fn clamp(self, min: Self, max: Self) -> Self
1.50.0[src]
impl<A: PartialEq + Angle> PartialEq<Latitude<A>> for Latitude<A>
[src]
impl<A: PartialOrd + Angle> PartialOrd<Latitude<A>> for Latitude<A>
[src]
fn partial_cmp(&self, other: &Latitude<A>) -> Option<Ordering>
[src]
#[must_use]pub fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]pub fn le(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]pub fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
#[must_use]pub fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
impl<A: Angle> StructuralEq for Latitude<A>
[src]
impl<A: Angle> StructuralPartialEq for Latitude<A>
[src]
impl<A: Angle> Sub<A> for Latitude<A>
[src]
type Output = Result<Self, A::NumErr>
The resulting type after applying the -
operator.
fn sub(self, rhs: A) -> Self::Output
[src]
Represent the south movement
impl<A: Angle> Sub<Latitude<A>> for Latitude<A>
[src]
type Output = Result<A, A::NumErr>
The resulting type after applying the -
operator.
fn sub(self, rhs: Self) -> Self::Output
[src]
impl<A: Angle> TryFrom<[i16; 2]> for Latitude<A> where
Self: TryFrom<[i16; 4], Error = <A as Angle>::NumErr>,
[src]
Self: TryFrom<[i16; 4], Error = <A as Angle>::NumErr>,
type Error = A::NumErr
The type returned in the event of a conversion error.
fn try_from(value: [i16; 2]) -> Result<Self, Self::Error>
[src]
impl<A: Angle> TryFrom<[i16; 3]> for Latitude<A> where
Self: TryFrom<[i16; 4], Error = <A as Angle>::NumErr>,
[src]
Self: TryFrom<[i16; 4], Error = <A as Angle>::NumErr>,
type Error = A::NumErr
The type returned in the event of a conversion error.
fn try_from(value: [i16; 3]) -> Result<Self, Self::Error>
[src]
impl TryFrom<[i16; 4]> for Latitude<AccurateDegree>
[src]
type Error = <AccurateDegree as Angle>::NumErr
The type returned in the event of a conversion error.
fn try_from(value: [i16; 4]) -> Result<Self, Self::Error>
[src]
impl TryFrom<[i16; 4]> for Latitude<DecimalDegree>
[src]
type Error = <DecimalDegree as Angle>::NumErr
The type returned in the event of a conversion error.
fn try_from(value: [i16; 4]) -> Result<Self, Self::Error>
[src]
impl<A: Angle> TryFrom<(i8, u8, u8, u16)> for Latitude<A> where
A: TryFrom<(u16, u8, u8, u16), Error = <A as Angle>::NumErr>,
[src]
A: TryFrom<(u16, u8, u8, u16), Error = <A as Angle>::NumErr>,
type Error = A::NumErr
The type returned in the event of a conversion error.
fn try_from(value: (i8, u8, u8, u16)) -> Result<Self, Self::Error>
[src]
impl<A: Angle> TryFrom<(i8, u8, u8)> for Latitude<A> where
Self: TryFrom<(i8, u8, u8, u16), Error = <A as Angle>::NumErr>,
[src]
Self: TryFrom<(i8, u8, u8, u16), Error = <A as Angle>::NumErr>,
type Error = A::NumErr
The type returned in the event of a conversion error.
fn try_from(value: (i8, u8, u8)) -> Result<Self, Self::Error>
[src]
impl<A: Angle> TryFrom<(i8, u8)> for Latitude<A> where
Self: TryFrom<(i8, u8, u8, u16), Error = <A as Angle>::NumErr>,
[src]
Self: TryFrom<(i8, u8, u8, u16), Error = <A as Angle>::NumErr>,
type Error = A::NumErr
The type returned in the event of a conversion error.
fn try_from(value: (i8, u8)) -> Result<Self, Self::Error>
[src]
impl<A: Angle> TryFrom<f64> for Latitude<A>
[src]
type Error = A::NumErr
The type returned in the event of a conversion error.
fn try_from(value: f64) -> Result<Self, Self::Error>
[src]
impl<A: Angle> TryFrom<i8> for Latitude<A> where
Self: TryFrom<(i8, u8, u8, u16), Error = <A as Angle>::NumErr>,
[src]
Self: TryFrom<(i8, u8, u8, u16), Error = <A as Angle>::NumErr>,
Auto Trait Implementations
impl<A> RefUnwindSafe for Latitude<A> where
A: RefUnwindSafe,
A: RefUnwindSafe,
impl<A> Send for Latitude<A> where
A: Send,
A: Send,
impl<A> Sync for Latitude<A> where
A: Sync,
A: Sync,
impl<A> Unpin for Latitude<A> where
A: Unpin,
A: Unpin,
impl<A> UnwindSafe for Latitude<A> where
A: UnwindSafe,
A: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,