timerPickerHourLabel method

  1. @override
String? timerPickerHourLabel(
  1. int hour
)
override

Label that appears next to the hour picker in CupertinoTimerPicker when selected hour value is hour. This function will deal with pluralization based on the hour parameter.

Implementation

@override
String? timerPickerHourLabel(int hour) {
  return intl.Intl.pluralLogic(
    hour,
    zero: timerPickerHourLabelZero,
    one: timerPickerHourLabelOne,
    two: timerPickerHourLabelTwo,
    few: timerPickerHourLabelFew,
    many: timerPickerHourLabelMany,
    other: timerPickerHourLabelOther,
    locale: _localeName,
  )?.replaceFirst(r'$hour', _decimalFormat.format(hour));
}