Package-level declarations

Types

Link copied to clipboard

Specialization of PolyglotValueLocalizer that allows to localize a date/time value T and returns a simple String.

Link copied to clipboard

Specialization of PolyglotValueLocalizer that allows to localize a Zoned date/time value T and returns a simple String.

Link copied to clipboard
sealed interface PolyglotLocalizer

Marker interface for all localizer classes of datetime-polyglot.

Link copied to clipboard

Interface that all options classes implement.

Link copied to clipboard

Specialization of PolyglotReferenceValueLocalizer that allows to localize a date/time value T and returns a TickingValue<String>.

Link copied to clipboard

Specialization of PolyglotReferenceDateTimeLocalizer that allows to localize a Zoned date/time value T and returns a TickingValue<String>.

Link copied to clipboard

A generic PolyglotLocalizer that accepts a value of type T and a Zoned<Instant> reference point, and returns a TickingValue of type R.

Link copied to clipboard

A generic PolyglotLocalizer that accepts a just value of type T and returns a result of type R.

Functions

Link copied to clipboard
fun <T, R> PolyglotReferenceValueLocalizer<T, R>.localizeAsFlow(value: T, clock: Flow<ClockWrapper> = SYSTEM_CLOCK, timeZone: Flow<TimeZone> = SYSTEM_TIMEZONE, maxTick: Duration? = null): Flow<R>

Localizes value by using the given clock's Clock.now and timeZone flows as a reference point and returns a Flow that emits updated values based on the underlying TickingValue.nextTick. This function assumes that each Clock emitted by the clock flow moves forward linearly.

Link copied to clipboard
fun <T, R> PolyglotReferenceValueLocalizer<T, R>.localizeNow(value: T, clock: Clock = Clock.System, timeZone: TimeZone = TimeZone.currentSystemDefault()): TickingValue<R>

Localizes value by using the given clock's Clock.now and timeZone as a reference point, rather than passing the reference explicitly.

Link copied to clipboard