NotificationScheduler class
Utility class for scheduling notifications with timezone support.
Constructors
- NotificationScheduler.new()
-
Creates a notification scheduler.
const
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
adjustForQuietHours(
{required DateTime scheduledTime, required int quietStartHour, required int quietEndHour, List< int> quietDays = const <int>[]}) → DateTime - Adjusts scheduled time to avoid quiet hours.
-
getNextOccurrence(
{required DateTime lastOccurrence, required RepeatInterval repeatInterval, String? timeZone}) → TZDateTime? - Calculates the next occurrence of a recurring notification.
-
isInQuietHours(
{required DateTime scheduledTime, required int quietStartHour, required int quietEndHour, List< int> quietDays = const <int>[]}) → bool - Checks if a scheduled time conflicts with quiet hours.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
scheduleNotification(
{required NotificationPayload payload, required DateTime scheduledTime, String? timeZone}) → Future< NotificationFailure?> - Schedules a notification for a specific date and time.
-
scheduleRecurringNotification(
{required NotificationPayload payload, required DateTime firstScheduledTime, required RepeatInterval repeatInterval, String? timeZone, DateTime? endDate}) → Future< NotificationFailure?> - Schedules a recurring notification.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited