wordBased

fun wordBased(period: Period, locale: Locale): String(source)

Formats a period to a string in a localized word-based format.

This returns a word-based format for the period. The year and month are printed as supplied unless the signs differ, in which case they are normalized. The words are configured in a resource bundle text file - org.threeten.extra.wordbased.properties - with overrides per language.

Return

the localized word-based format for the period

Parameters

period

the period to format

locale

the locale to use


fun wordBased(duration: Duration, locale: Locale): String(source)

Formats a duration to a string in a localized word-based format.

This returns a word-based format for the duration. The words are configured in a resource bundle text file - org.threeten.extra.wordbased.properties - with overrides per language.

Return

the localized word-based format for the duration

Parameters

duration

the duration to format

locale

the locale to use


fun wordBased(period: Period, duration: Duration, locale: Locale): String(source)

Formats a period and duration to a string in a localized word-based format.

This returns a word-based format for the period. The year and month are printed as supplied unless the signs differ, in which case they are normalized. The words are configured in a resource bundle text file - org.threeten.extra.wordbased.properties - with overrides per language.

Return

the localized word-based format for the period and duration

Parameters

period

the period to format

duration

the duration to format

locale

the locale to use