doc / ch.tutteli.atrium.domain.builders.reporting / TranslatorOption

TranslatorOption

expect interface TranslatorOption : TranslatorOptionCommon (source)
Deprecated: Configure components via withOptions when creating an expectation verb instead; will be removed with 0.17.0

Provides options to create a Translator -- the platform specific interface might provide further options.

Inherited Properties

localeOrderDecider

abstract val localeOrderDecider: LocaleOrderDecider

The previously chosen LocaleOrderDecider.

translationSupplier

abstract val translationSupplier: TranslationSupplier

The previously chosen TranslationSupplier.

Functions

withDefaultTranslator

open fun withDefaultTranslator(primaryLocale: Locale, vararg fallbackLocales: Locale): ObjectFormatterOption

Uses CoreFactory.newTranslator as Translator where the specified translationSupplier is used to retrieve translations, the specified localeOrderDecider to determine candidate java.util.Locales and primaryLocale is used as primary java.util.Locale and the optional fallbackLocales as fallback java.util.Locales.

Inherited Functions

withDefaultTranslator

abstract fun withDefaultTranslator(primaryLocale: Locale, vararg fallbackLocales: Locale): ObjectFormatterOption

Uses CoreFactory.newTranslator as Translator where the specified translationSupplier is used to retrieve translations, the specified localeOrderDecider to determine candidate Locales and primaryLocale is used as primary Locale and the optional fallbackLocales as fallback Locales.

withTranslator

abstract fun withTranslator(factory: (TranslationSupplier, LocaleOrderDecider) -> Translator): ObjectFormatterOption

Uses the given factory to build a Translator.