Format
actual fun Format(block: DateTimeFormatBuilder.WithDate.() -> Unit): DateTimeFormat<LocalDate>(source)
expect fun Format(block: DateTimeFormatBuilder.WithDate.() -> Unit): DateTimeFormat<LocalDate>(source)
Creates a new format for parsing and formatting LocalDate values.
Example:
// 2020 Jan 05
LocalDate.Format {
year()
char(' ')
monthName(MonthNames.ENGLISH_ABBREVIATED)
char(' ')
dayOfMonth()
}
Content copied to clipboard
Only parsing and formatting of well-formed values is supported. If the input does not fit the boundaries (for example, dayOfMonth is 31 for February), consider using DateTimeComponents.Format instead.
There is a collection of predefined formats in LocalDate.Formats.
actual fun Format(block: DateTimeFormatBuilder.WithDate.() -> Unit): DateTimeFormat<LocalDate>(source)
actual fun Format(block: DateTimeFormatBuilder.WithDate.() -> Unit): DateTimeFormat<LocalDate>(source)