Enum time::format_description::Component [−][src]
#[non_exhaustive]
pub enum Component {
Show 14 variants
Day(Day),
Month(Month),
Ordinal(Ordinal),
Weekday(Weekday),
WeekNumber(WeekNumber),
Year(Year),
Hour(Hour),
Minute(Minute),
Period(Period),
Second(Second),
Subsecond(Subsecond),
OffsetHour(OffsetHour),
OffsetMinute(OffsetMinute),
OffsetSecond(OffsetSecond),
}
This is supported on crate features
formatting
or parsing
only.Expand description
A component of a larger format description.
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Day of the month.
Tuple Fields of Day
0: Day
Month of the year.
Tuple Fields of Month
0: Month
Ordinal day of the year.
Tuple Fields of Ordinal
0: Ordinal
Day of the week.
Tuple Fields of Weekday
0: Weekday
Week within the year.
Tuple Fields of WeekNumber
0: WeekNumber
Year of the date.
Tuple Fields of Year
0: Year
Hour of the day.
Tuple Fields of Hour
0: Hour
Minute within the hour.
Tuple Fields of Minute
0: Minute
AM/PM part of the time.
Tuple Fields of Period
0: Period
Second within the minute.
Tuple Fields of Second
0: Second
Subsecond within the second.
Tuple Fields of Subsecond
0: Subsecond
Hour of the UTC offset.
Tuple Fields of OffsetHour
0: OffsetHour
Minute within the hour of the UTC offset.
Tuple Fields of OffsetMinute
0: OffsetMinute
Second within the minute of the UTC offset.
Tuple Fields of OffsetSecond
0: OffsetSecond
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Component
impl UnwindSafe for Component
Blanket Implementations
Mutably borrows from an owned value. Read more