This module defines the Formatter types. It is based on the Java's DateTimeFormatter format.
The part of a formatting string. A string is just a text and a modifier is in the format described in
the Modifier type.
- string
(val : String)
: FormatPart
A string literal.
- modifier
(modifier : Modifier)
: FormatPart
A modifier that renders some data into text.
Instances For
The format of date and time string.
Instances For
Configuration options for formatting and parsing date/time strings.
- allowLeapSeconds : Bool
Whether to allow leap seconds, such as
2016-12-31T23:59:60Z. Default isfalse. - dateformat : DateFormat
Locale configuration for formatting and parsing, including locale-specific symbols and the first day of the week used for week-of-year and week-of-month calculations. Default is
DateFormat.enUS(English, US).
Instances For
A specification on how to format a data or parse some string.
- config : FormatConfig
Configuration options for formatting behavior.
- string : FormatString
The format string used for parsing and formatting.
Instances For
Classify a PlainTime into a DayPeriod for the b pattern.
Instances For
Classify a PlainTime into an ExtendedDayPeriod for the B pattern (CLDR flexible periods).
Instances For
Parses a short month name using the given locale symbols and returns the corresponding Month.Ordinal.
Instances For
Constructs a new GenericFormat specification for a date-time string. Modifiers can be combined to create
custom formats, such as "YYYY, MMMM, D".
Instances For
Builds a GenericFormat from the input string. If parsing fails, it will panic
Instances For
Formats a DateTime value into a string using the given GenericFormat.
Instances For
Parser for a format with a builder.
Instances For
Parses the input string into a DateTime.
Instances For
Parses the input string into a DateTime and panics if its wrong.
Instances For
Parses an input string using a builder function to produce a value.
Instances For
Parses an input string using a builder function, panicking on errors.
Instances For
Formats the date using the format into a String, using a getInfo function to get the information needed to build the String.
Instances For
Constructs a FormatType function to format a date into a string using a GenericFormat.
Instances For
Typeclass for formatting and parsing values with the given format type.
- format (fmt : f) : typ String fmt
Converts a format
finto a string. Parses a string into a format using the provided format type
f.