Enum time::format_description::well_known::iso8601::TimePrecision
source · pub enum TimePrecision {
Hour {
decimal_digits: Option<NonZeroU8>,
},
Minute {
decimal_digits: Option<NonZeroU8>,
},
Second {
decimal_digits: Option<NonZeroU8>,
},
}
Expand description
The precision and number of decimal digits present for the time.
Variants§
Hour
Format the hour only. Minutes, seconds, and nanoseconds will be represented with the specified number of decimal digits, if any.
Minute
Format the hour and minute. Seconds and nanoseconds will be represented with the specified number of decimal digits, if any.
Second
Format the hour, minute, and second. Nanoseconds will be represented with the specified number of decimal digits, if any.
Trait Implementations§
source§impl Clone for TimePrecision
impl Clone for TimePrecision
source§fn clone(&self) -> TimePrecision
fn clone(&self) -> TimePrecision
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for TimePrecision
impl Debug for TimePrecision
source§impl PartialEq<TimePrecision> for TimePrecision
impl PartialEq<TimePrecision> for TimePrecision
source§fn eq(&self, other: &TimePrecision) -> bool
fn eq(&self, other: &TimePrecision) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.