NotificationAndroidCrontab.minutely constructor

NotificationAndroidCrontab.minutely({
  1. required DateTime referenceDateTime,
  2. bool allowWhileIdle = false,
})

Generates a Cron expression to be played only once at every minute based on a date reference

Implementation

NotificationAndroidCrontab.minutely(
    {required DateTime referenceDateTime, bool allowWhileIdle = false})
    : super(
          timeZone: referenceDateTime.isUtc
              ? LocalNotifications.utcTimeZoneIdentifier
              : LocalNotifications.localTimeZoneIdentifier,
          allowWhileIdle: allowWhileIdle,
          repeats: false) {
  _crontabExpression =
      CronHelper().minutely(initialSecond: referenceDateTime.second);
}