pub struct Eccentricity(/* private fields */);Expand description
Orbital eccentricity.
Implementations§
Source§impl Eccentricity
impl Eccentricity
Sourcepub const fn try_new(
ecc: f64,
) -> Result<Eccentricity, NegativeEccentricityError>
pub const fn try_new( ecc: f64, ) -> Result<Eccentricity, NegativeEccentricityError>
Tries to create a new Eccentricity instance from an f64 value.
§Errors
Returns a NegativeEccentricityError if the value is smaller than zero.
Sourcepub fn orbit_type(&self) -> OrbitType
pub fn orbit_type(&self) -> OrbitType
Returns the OrbitType based on the eccentricity.
Sourcepub fn is_circular(&self) -> bool
pub fn is_circular(&self) -> bool
Checks if the orbit is circular.
Sourcepub fn is_elliptic(&self) -> bool
pub fn is_elliptic(&self) -> bool
Checks if the orbit is elliptic.
Sourcepub fn is_parabolic(&self) -> bool
pub fn is_parabolic(&self) -> bool
Checks if the orbit is parabolic.
Sourcepub fn is_hyperbolic(&self) -> bool
pub fn is_hyperbolic(&self) -> bool
Checks if the orbit is hyperbolic.
Sourcepub fn is_circular_or_elliptic(&self) -> bool
pub fn is_circular_or_elliptic(&self) -> bool
Checks if the orbit is circular or elliptic.
Trait Implementations§
Source§impl ApproxEq for Eccentricity
impl ApproxEq for Eccentricity
Source§impl Clone for Eccentricity
impl Clone for Eccentricity
Source§fn clone(&self) -> Eccentricity
fn clone(&self) -> Eccentricity
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for Eccentricity
impl Debug for Eccentricity
Source§impl Default for Eccentricity
impl Default for Eccentricity
Source§fn default() -> Eccentricity
fn default() -> Eccentricity
Returns the “default value” for a type. Read more
Source§impl Display for Eccentricity
impl Display for Eccentricity
Source§impl PartialEq for Eccentricity
impl PartialEq for Eccentricity
Source§impl PartialOrd for Eccentricity
impl PartialOrd for Eccentricity
impl Copy for Eccentricity
impl StructuralPartialEq for Eccentricity
Auto Trait Implementations§
impl Freeze for Eccentricity
impl RefUnwindSafe for Eccentricity
impl Send for Eccentricity
impl Sync for Eccentricity
impl Unpin for Eccentricity
impl UnsafeUnpin for Eccentricity
impl UnwindSafe for Eccentricity
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