setMultiNotificationMode
Enables or disables multi-notification mode.
By default, the SDK uses single notification mode where each new notification replaces the previous one in the notification tray. When multi-notification mode is enabled, each notification is displayed separately, allowing users to see multiple notifications at once.
Single Mode (default): Only the latest notification is visibleMulti Mode: All notifications are visible in the tray Example:
// E-commerce app - show multiple order notifications
public class ShoppingApp extends Application {
public void onCreate() {
super.onCreate();
Pushwoosh.getInstance().registerForPushNotifications();
// Enable multi-notification mode for order updates
PushwooshNotificationSettings.setMultiNotificationMode(true);
// Now users can see: "Order shipped", "Order delivered", etc.
}
}
// Messaging app - single mode to avoid clutter
public class MessagingApp extends Application {
public void onCreate() {
super.onCreate();
Pushwoosh.getInstance().registerForPushNotifications();
// Keep only latest message notification
PushwooshNotificationSettings.setMultiNotificationMode(false);
}
}
Content copied to clipboard
Parameters
on
true to show multiple notifications, false to show only the latest