pub struct PartMonthBuilder<'vf, T: ValueFormatTrait> { /* private fields */ }Expand description
Builder for FormatPart with type Month.
The number:month element specifies a month in a date.
The number:month element is usable within the following element:
- number:date-style 16.27.10.
The number:month element has the following attributes: number:calendar 19.341, number:possessive-form 19.355, number:style 19.358.7 and number:textual 19.359.
The number:month element has no child elements
Implementations§
Source§impl<'vf, T: ValueFormatTrait> PartMonthBuilder<'vf, T>
impl<'vf, T: ValueFormatTrait> PartMonthBuilder<'vf, T>
Sourcepub fn if_then<F>(self, test: bool, build: F) -> Selfwhere
F: Fn(Self) -> Self,
pub fn if_then<F>(self, test: bool, build: F) -> Selfwhere
F: Fn(Self) -> Self,
Only applies the builder if the test is true.
Sourcepub fn long_style(self) -> Self
pub fn long_style(self) -> Self
The number:style attribute specifies whether the content of a time element is displayed in short or long format. The value of this attribute can be short or long. The meaning of these values depends on the value of the number:format-source 19.348 attribute that is attached to a date or time style.
Sourcepub fn short_style(self) -> Self
pub fn short_style(self) -> Self
The number:style attribute specifies whether the content of a time element is displayed in short or long format. The value of this attribute can be short or long. The meaning of these values depends on the value of the number:format-source 19.348 attribute that is attached to a date or time style.
Sourcepub fn style(self, style: FormatNumberStyle) -> Self
pub fn style(self, style: FormatNumberStyle) -> Self
The number:style attribute specifies whether the content of a time element is displayed in short or long format. The value of this attribute can be short or long. The meaning of these values depends on the value of the number:format-source 19.348 attribute that is attached to a date or time style.
Sourcepub fn textual(self) -> Self
pub fn textual(self) -> Self
The number:textual attribute specifies whether the name or number of a month is displayed in the month portion of a date.
The defined values for the number:textual element are:
- false: the number of the month is displayed.
- true: the name of the month is displayed.
The name or number of a month is defined by the number:calendar 19.341 attribute on the same parent element as the number:textual attribute. The default value for this attribute is false.
Sourcepub fn possessive_form(self) -> Self
pub fn possessive_form(self) -> Self
The number:possessive-form attribute specifies whether the month is displayed as a noun or using the possessive form. The number:possessive-form attribute is only applied when a number:textual 19.363 attribute on the same number:month element has the value of true.
The defined values for the number:possessive-form attribute are:
- false: the name of the month is displayed in nominative form.
- true: the name of the month is displayed in possessive form.
Sourcepub fn calendar(self, calendar: FormatCalendarStyle) -> Self
pub fn calendar(self, calendar: FormatCalendarStyle) -> Self
The number:calendar attribute specifies the calendar system used to extract parts of a date.
The attribute value may also be a string value. If this attribute is not specified, the default calendar system for the locale of the data style is used.