Caplin Trader 5.1.0

Module: br-i18n/I18N

Provides i18n functions. Accessed via the br/I18n class.

Methods

(static) date(thingToFormat)

Returns a data formatted according to the current locale settings.

Parameters:
Name Type Description
thingToFormat String

The data to format

See:
  • br-i18n/Translator:#formatDate

(static) dateTime(thingToFormat)

Returns a date time formatted according to the current locale settings.

Parameters:
Name Type Description
thingToFormat String

The date to format

(static) getTranslator()

Returns the Translator used.

(static) i18n(thingToFormat, mTemplateArgsopt)

Returns the translation for a message using the current locale.

Parameters:
Name Type Attributes Description
thingToFormat String

The translation key.

mTemplateArgs object <optional>

Arguments provided by the template

See:
  • br-i18n/Translator:#getMessage

(static) number(thingToFormat)

Returns a number formatted according to the current locale settings.

Parameters:
Name Type Description
thingToFormat String

The number to format

See:
  • br-i18n/Translator:#formatNumber

(static) time(thingToFormat)

Returns a time formatted according to the current locale settings.

Parameters:
Name Type Description
thingToFormat String

The time to format

See:
  • br-i18n/Translator:#formatTime