YearLocalizer

Localizer for years (Int).

Because kotlinx-datetime doesn't provide a standard type for a year, there is no extension function equivalent for one-off localizations.

Examples:

  • 2026

  • 26

  • 2026 AD

  • 2026 Anno Domini

Localizer for years (Int).

Because kotlinx-datetime doesn't provide a standard type for a year, there is no extension function equivalent for one-off localizations.

Examples:

  • 2026

  • 26

  • 2026 AD

  • 2026 Anno Domini

Localizer for years (Int).

Because kotlinx-datetime doesn't provide a standard type for a year, there is no extension function equivalent for one-off localizations.

Examples:

  • 2026

  • 26

  • 2026 AD

  • 2026 Anno Domini

Constructors

Link copied to clipboard
expect constructor(options: YearOptions, locale: PlatformLocale = getDefaultLocale())
actual constructor(options: YearOptions, locale: PlatformLocale)
actual constructor(options: YearOptions, locale: PlatformLocale)

Functions

Link copied to clipboard
expect open override fun localize(value: Int): String
actual open override fun localize(value: Int): String
actual open override fun localize(value: Int): String