[][src]Struct unix::time::EpochTime

pub struct EpochTime(_);

Time measured since the Unix epoch

The Unix epoch = Julian date 2440587.5 = Gregorian date January 1st 1970 00:00 UTC

Implementations

impl EpochTime[src]

pub fn now() -> Self[src]

Return the present time.

pub fn from_ns_since_epoch(n: i128) -> Self[src]

Convert from nanoseconds since the Unix epoch to an EpochTime.

pub fn to_ns_since_epoch(self) -> i128[src]

Convert from an EpochTime to nanoseconds since the Unix epoch.

Trait Implementations

impl Add<Span> for EpochTime[src]

type Output = Self

The resulting type after applying the + operator.

impl AddAssign<Span> for EpochTime[src]

impl Clone for EpochTime[src]

impl Copy for EpochTime[src]

impl Debug for EpochTime[src]

impl Eq for EpochTime[src]

impl Hash for EpochTime[src]

impl Ord for EpochTime[src]

impl PartialEq<EpochTime> for EpochTime[src]

impl PartialOrd<EpochTime> for EpochTime[src]

impl StructuralEq for EpochTime[src]

impl StructuralPartialEq for EpochTime[src]

impl Sub<EpochTime> for EpochTime[src]

type Output = Span

The resulting type after applying the - operator.

impl Sub<Span> for EpochTime[src]

type Output = Self

The resulting type after applying the - operator.

impl SubAssign<Span> for EpochTime[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> TryClone for T where
    T: Clone
[src]

type Error = Void

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.