pub struct Latitude(/* private fields */);Expand description
Geographic latitude in degrees, -90.0..=90.0.
Implementations§
Source§impl Latitude
impl Latitude
Sourcepub fn new(value: f64) -> Result<Latitude, OutOfRange>
pub fn new(value: f64) -> Result<Latitude, OutOfRange>
Constructs a new value, validating the range.
§Errors
Returns OutOfRange if value is NaN or outside the
valid range.
Sourcepub const fn new_unchecked(value: f64) -> Latitude
pub const fn new_unchecked(value: f64) -> Latitude
Constructs without validation.
The caller must ensure value lies within the valid range.
Trait Implementations§
impl Copy for Latitude
Source§impl PartialOrd for Latitude
impl PartialOrd for Latitude
impl StructuralPartialEq for Latitude
Auto Trait Implementations§
impl Freeze for Latitude
impl RefUnwindSafe for Latitude
impl Send for Latitude
impl Sync for Latitude
impl Unpin for Latitude
impl UnsafeUnpin for Latitude
impl UnwindSafe for Latitude
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