DateTimeFormatterSkeletonOptions.Builder


class DateTimeFormatterSkeletonOptions.Builder


The Builder class used to construct a DateTimeFormatterSkeletonOptions in a way that is safe and discoverable.

Summary

Public functions

DateTimeFormatterSkeletonOptions

Builds the immutable DateTimeFormatterSkeletonOptions to use with DateTimeFormatter.

DateTimeFormatterSkeletonOptions.Builder

Set the day presence and length to use for formatting.

DateTimeFormatterSkeletonOptions.Builder

Set the era presence and length to use for formatting.

DateTimeFormatterSkeletonOptions.Builder

Set the fractional second presence and length to use for formatting.

DateTimeFormatterSkeletonOptions.Builder

Set the hour presence and length to use for formatting.

DateTimeFormatterSkeletonOptions.Builder

Set the minute presence and length to use for formatting.

DateTimeFormatterSkeletonOptions.Builder

Set the month presence and length to use for formatting.

DateTimeFormatterSkeletonOptions.Builder

Set the day period presence and length to use for formatting.

DateTimeFormatterSkeletonOptions.Builder

Set the second presence and length to use for formatting.

DateTimeFormatterSkeletonOptions.Builder

Set the timezone presence and length to use for formatting.

DateTimeFormatterSkeletonOptions.Builder

Set the day of week presence and length to use for formatting.

DateTimeFormatterSkeletonOptions.Builder

Set the year presence and length to use for formatting.

Public constructors

Builder

Added in 1.0.0-alpha01
Builder(
    era: DateTimeFormatterSkeletonOptions.Era = Era.NONE,
    year: DateTimeFormatterSkeletonOptions.Year = Year.NONE,
    month: DateTimeFormatterSkeletonOptions.Month = Month.NONE,
    day: DateTimeFormatterSkeletonOptions.Day = Day.NONE,
    weekDay: DateTimeFormatterSkeletonOptions.WeekDay = WeekDay.NONE,
    period: DateTimeFormatterSkeletonOptions.Period = Period.NONE,
    hour: DateTimeFormatterSkeletonOptions.Hour = Hour.NONE,
    minute: DateTimeFormatterSkeletonOptions.Minute = Minute.NONE,
    second: DateTimeFormatterSkeletonOptions.Second = Second.NONE,
    fractionalSecond: DateTimeFormatterSkeletonOptions.FractionalSecond = FractionalSecond.NONE,
    timezone: DateTimeFormatterSkeletonOptions.Timezone = Timezone.NONE
)

Public functions

setDay

Added in 1.0.0-alpha01
fun setDay(day: DateTimeFormatterSkeletonOptions.Day): DateTimeFormatterSkeletonOptions.Builder

Set the day presence and length to use for formatting.

Parameters
day: DateTimeFormatterSkeletonOptions.Day

the era style to use.

setEra

Added in 1.0.0-alpha01
fun setEra(era: DateTimeFormatterSkeletonOptions.Era): DateTimeFormatterSkeletonOptions.Builder

Set the era presence and length to use for formatting.

Parameters
era: DateTimeFormatterSkeletonOptions.Era

the era style to use.

setFractionalSecond

Added in 1.0.0-alpha01
fun setFractionalSecond(
    fractionalSecond: DateTimeFormatterSkeletonOptions.FractionalSecond
): DateTimeFormatterSkeletonOptions.Builder

Set the fractional second presence and length to use for formatting.

Parameters
fractionalSecond: DateTimeFormatterSkeletonOptions.FractionalSecond

the era style to use.

setHour

Added in 1.0.0-alpha01
fun setHour(hour: DateTimeFormatterSkeletonOptions.Hour): DateTimeFormatterSkeletonOptions.Builder

Set the hour presence and length to use for formatting.

Parameters
hour: DateTimeFormatterSkeletonOptions.Hour

the era style to use.

setMinute

Added in 1.0.0-alpha01
fun setMinute(minute: DateTimeFormatterSkeletonOptions.Minute): DateTimeFormatterSkeletonOptions.Builder

Set the minute presence and length to use for formatting.

Parameters
minute: DateTimeFormatterSkeletonOptions.Minute

the era style to use.

setMonth

Added in 1.0.0-alpha01
fun setMonth(month: DateTimeFormatterSkeletonOptions.Month): DateTimeFormatterSkeletonOptions.Builder

Set the month presence and length to use for formatting.

Parameters
month: DateTimeFormatterSkeletonOptions.Month

the era style to use.

setPeriod

Added in 1.0.0-alpha01
fun setPeriod(period: DateTimeFormatterSkeletonOptions.Period): DateTimeFormatterSkeletonOptions.Builder

Set the day period presence and length to use for formatting.

Parameters
period: DateTimeFormatterSkeletonOptions.Period

the era style to use.

setSecond

Added in 1.0.0-alpha01
fun setSecond(second: DateTimeFormatterSkeletonOptions.Second): DateTimeFormatterSkeletonOptions.Builder

Set the second presence and length to use for formatting.

Parameters
second: DateTimeFormatterSkeletonOptions.Second

the era style to use.

setTimezone

Added in 1.0.0-alpha01
fun setTimezone(timezone: DateTimeFormatterSkeletonOptions.Timezone): DateTimeFormatterSkeletonOptions.Builder

Set the timezone presence and length to use for formatting.

Parameters
timezone: DateTimeFormatterSkeletonOptions.Timezone

the era style to use.

setWeekDay

Added in 1.0.0-alpha01
fun setWeekDay(weekDay: DateTimeFormatterSkeletonOptions.WeekDay): DateTimeFormatterSkeletonOptions.Builder

Set the day of week presence and length to use for formatting.

Parameters
weekDay: DateTimeFormatterSkeletonOptions.WeekDay

the era style to use.

setYear

Added in 1.0.0-alpha01
fun setYear(year: DateTimeFormatterSkeletonOptions.Year): DateTimeFormatterSkeletonOptions.Builder

Set the year presence and length to use for formatting.

Parameters
year: DateTimeFormatterSkeletonOptions.Year

the era style to use.