pub struct AstronomicalEpoch { /* private fields */ }Implementations§
Source§impl AstronomicalEpoch
impl AstronomicalEpoch
Sourcepub fn new(label: impl AsRef<str>, kind: EpochKind) -> Result<Self, EpochError>
pub fn new(label: impl AsRef<str>, kind: EpochKind) -> Result<Self, EpochError>
Creates an astronomical epoch with a non-empty label and kind.
§Errors
Returns EpochError::EmptyLabel when the trimmed label is empty.
pub fn j2000() -> Self
pub fn b1950() -> Self
pub fn label(&self) -> &str
pub const fn kind(&self) -> &EpochKind
Trait Implementations§
Source§impl Clone for AstronomicalEpoch
impl Clone for AstronomicalEpoch
Source§fn clone(&self) -> AstronomicalEpoch
fn clone(&self) -> AstronomicalEpoch
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 AstronomicalEpoch
impl Debug for AstronomicalEpoch
Source§impl PartialEq for AstronomicalEpoch
impl PartialEq for AstronomicalEpoch
impl Eq for AstronomicalEpoch
impl StructuralPartialEq for AstronomicalEpoch
Auto Trait Implementations§
impl Freeze for AstronomicalEpoch
impl RefUnwindSafe for AstronomicalEpoch
impl Send for AstronomicalEpoch
impl Sync for AstronomicalEpoch
impl Unpin for AstronomicalEpoch
impl UnsafeUnpin for AstronomicalEpoch
impl UnwindSafe for AstronomicalEpoch
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