pub struct DateTimeParts {
pub year: i32,
pub month: u8,
pub day: u8,
pub hour: u8,
pub minute: u8,
pub second: u8,
pub millisecond: u32,
pub microsecond: u32,
pub nanosecond: u32,
}
Expand description
The parts that make up a date/time.
Fields§
§year: i32
§month: u8
§day: u8
§hour: u8
§minute: u8
§second: u8
§millisecond: u32
§microsecond: u32
§nanosecond: u32
Implementations§
Trait Implementations§
Source§impl Debug for DateTimeParts
impl Debug for DateTimeParts
Source§impl Default for DateTimeParts
impl Default for DateTimeParts
Source§fn default() -> DateTimeParts
fn default() -> DateTimeParts
Returns the “default value” for a type. Read more
Source§impl TryFrom<DateTimeParts> for Epoch
impl TryFrom<DateTimeParts> for Epoch
Source§fn try_from(parts: DateTimeParts) -> Result<Self>
fn try_from(parts: DateTimeParts) -> Result<Self>
Attempts to convert DateTimeParts into an Epoch
Source§type Error = EpochError
type Error = EpochError
The type returned in the event of a conversion error.
Auto Trait Implementations§
impl Freeze for DateTimeParts
impl RefUnwindSafe for DateTimeParts
impl Send for DateTimeParts
impl Sync for DateTimeParts
impl Unpin for DateTimeParts
impl UnwindSafe for DateTimeParts
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