pub struct UtcTime { /* private fields */ }Expand description
An instant in Coordinated Universal Time, as seconds since 1970-01-01T00:00:00Z (leap seconds not counted, as in POSIX time).
Implementations§
Source§impl UtcTime
impl UtcTime
Sourcepub fn from_unix_seconds(seconds: f64) -> Result<Self, Era5Error>
pub fn from_unix_seconds(seconds: f64) -> Result<Self, Era5Error>
Sourcepub fn from_civil(
year: i32,
month: u32,
day: u32,
hour: u32,
minute: u32,
second: f64,
) -> Result<Self, Era5Error>
pub fn from_civil( year: i32, month: u32, day: u32, hour: u32, minute: u32, second: f64, ) -> Result<Self, Era5Error>
The instant at a date and time of the Gregorian calendar, in UTC.
§Errors
Era5Error::Domain for a month outside 1 to 12, a day not in the month, an hour past
23, a minute past 59, or a second outside [0, 60).
Sourcepub fn unix_seconds(self) -> f64
pub fn unix_seconds(self) -> f64
Seconds since 1970-01-01T00:00:00Z.
Trait Implementations§
impl Copy for UtcTime
Source§impl<'de> Deserialize<'de> for UtcTime
impl<'de> Deserialize<'de> for UtcTime
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialOrd for UtcTime
impl PartialOrd for UtcTime
impl StructuralPartialEq for UtcTime
Auto Trait Implementations§
impl Freeze for UtcTime
impl RefUnwindSafe for UtcTime
impl Send for UtcTime
impl Sync for UtcTime
impl Unpin for UtcTime
impl UnsafeUnpin for UtcTime
impl UnwindSafe for UtcTime
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