Skip to main content

Moment

Trait Moment 

pub trait Moment {
    // Required method
    fn local(&self) -> Option<NaiveDateTime>;
}
Expand description

A moment the formatters can show: a chrono date and time in any zone, a local NaiveDateTime or UnixSecs.

Required Methods§

fn local(&self) -> Option<NaiveDateTime>

The moment on the local wall clock, or None outside the calendar’s range.

Implementations on Foreign Types§

§

impl<Tz> Moment for DateTime<Tz>
where Tz: TimeZone,

Implementors§

§

impl Moment for NaiveDateTime

Already on the local wall clock.

§

impl Moment for UnixSecs