Module format_item

Source
Available on (crate features formatting or parsing) and crate feature alloc only.
Expand description

Typed, validated representation of a parsed format description.

Macros§

component_definition 🔒
Declare the Component struct.
modifier 🔒
Declare the various modifiers.
target_ty 🔒
Get the target type for a given enum.
target_value 🔒
Get the target value for a given enum.

Structs§

Day 🔒
End 🔒
Hour 🔒
Ignore 🔒
Minute 🔒
Month 🔒
OffsetHour 🔒
OffsetMinute 🔒
OffsetSecond 🔒
Ordinal 🔒
Period 🔒
Second 🔒
Subsecond 🔒
UnixTimestamp 🔒
WeekNumber 🔒
Weekday 🔒
Year 🔒

Enums§

Component 🔒
HourBase 🔒
Item 🔒
A description of how to format and parse one part of a type.
MonthCaseSensitive 🔒
MonthRepr 🔒
Padding 🔒
PeriodCase 🔒
PeriodCaseSensitive 🔒
SignBehavior 🔒
SubsecondDigits 🔒
UnixTimestampPrecision 🔒
WeekNumberRepr 🔒
WeekdayCaseSensitive 🔒
WeekdayOneIndexed 🔒
WeekdayRepr 🔒
YearBase 🔒
YearRange 🔒
YearRepr 🔒

Functions§

component_from_ast 🔒
Parse a component from the AST, given its name and modifiers.
parse 🔒
Parse an AST iterator into a sequence of format items.
parse_from_modifier_value 🔒
Parse a modifier value using FromStr. Requires the modifier value to be valid UTF-8.