toJson method

Map<String, dynamic> toJson()

Returns the data fields of AndroidNotificationOptions in JSON format.

Implementation

Map<String, dynamic> toJson() {
  return {
    'notificationId': id,
    'notificationChannelId': channelId,
    'notificationChannelName': channelName,
    'notificationChannelDescription': channelDescription,
    'notificationChannelImportance': channelImportance.rawValue,
    'notificationPriority': priority.rawValue,
    'enableVibration': enableVibration,
    'playSound': playSound,
    'showWhen': showWhen,
    'showBadge': showBadge,
    'onlyAlertOnce': onlyAlertOnce,
    'visibility': visibility.rawValue,
  };
}