configure static method
Future<void>
configure({
- required dynamic onNotificationArrival(),
- required dynamic onNotificationTap(),
- required MPAndroidNotificationsSettings androidNotificationsSettings,
Configures the MPush plugin with the callbacks. @param onNotificationArrival Called when a push notification arrives. @param onNotificationTap Called when a push notification is tapped. @param androidNotificationsSettings Settings for the android notification.
Implementation
static Future<void> configure({
required Function(Map<String, dynamic>) onNotificationArrival,
required Function(Map<String, dynamic>) onNotificationTap,
required MPAndroidNotificationsSettings androidNotificationsSettings,
}) {
_androidPushNotificationsSettings = androidNotificationsSettings;
return MPush.configure(
onNotificationArrival: onNotificationArrival,
onNotificationTap: onNotificationTap,
androidNotificationsSettings: androidNotificationsSettings,
);
}