UtcTime

Type Alias UtcTime 

Source
pub type UtcTime = TimePoint<Utc>;

Aliased Type§

pub struct UtcTime { /* private fields */ }

Trait Implementations§

Source§

impl FromDateTime for UtcTime

Source§

type Error = InvalidUtcDateTime

This error may be returned whenever some input date-time is not valid. This may be the case when the time-of-day is not valid, but also when some date-time does not occur in a chosen time scale, for example due to leap seconds deletions or daylight saving time switches.
Source§

fn from_datetime( date: Date, hour: u8, minute: u8, second: u8, ) -> Result<Self, Self::Error>

Maps a given combination of date and time-of-day to an instant on this time scale. May return an error if the input does not represent a valid combination of date and time-of-day.
Source§

impl IntoDateTime for UtcTime

Source§

fn into_datetime(self) -> (Date, u8, u8, u8)

Maps a time point back to the date and time-of-day that it represents. Returns a tuple of date, hour, minute, and second. This function shall not fail, unless overflow occurs in the underlying integer arithmetic.