setLocale method

FutureOr<bool> setLocale(
  1. dynamic locale
)

Sets the main locale for this instance.

Implementation

FutureOr<bool> setLocale(dynamic locale) {
  var intlLocale = IntlLocale(locale);
  if (_currentLocale == intlLocale) return false;

  _currentLocale = intlLocale;
  return _defineLocalesOrder(true);
}