FlutterLocalNotificationsPlatform class Null safety

The interface that all implementations of flutter_local_notifications must implement.

  • Object
  • PlatformInterface
  • FlutterLocalNotificationsPlatform


Constructs an instance of FlutterLocalNotificationsPlatform.


hashCode int
The hash code for this object.
runtimeType Type
A representation of the runtime type of the object.


cancel(int id) Future<void>
Cancel/remove the notification with the specified id.
cancelAll() Future<void>
Cancels/removes all notifications. This applies to notifications that have been scheduled and those that have already been presented.
getActiveNotifications() Future<List<ActiveNotification>>
Returns a list of notifications already delivered
getNotificationAppLaunchDetails() Future<NotificationAppLaunchDetails?>
Returns info on if a notification had been used to launch the application.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
pendingNotificationRequests() Future<List<PendingNotificationRequest>>
Returns a list of notifications pending to be delivered/shown
periodicallyShow(int id, String? title, String? body, RepeatInterval repeatInterval) Future<void>
Periodically show a notification using the specified interval. For example, specifying a hourly interval means the first time the notification will be an hour after the method has been called and then every hour after that.
show(int id, String? title, String? body, {String? payload}) Future<void>
Show a notification with an optional payload that will be passed back to the app when a notification is tapped on.
toString() String
A string representation of this object.


operator ==(Object other) bool
The equality operator.

Static Properties

instance FlutterLocalNotificationsPlatform
The default instance of FlutterLocalNotificationsPlatform to use.
read / write