toMap method
Exports all content into a serializable object
Implementation
@override
Map<String, dynamic> toMap() => {
NOTIFICATION_CONTENT: _content?.toMap() ?? {},
if (_schedule != null) NOTIFICATION_SCHEDULE: _schedule!.toMap(),
if (_actionButtons?.isNotEmpty ?? false)
NOTIFICATION_BUTTONS: [
for (NotificationActionButton button in _actionButtons!)
button.toMap()
],
if (_localizations?.isNotEmpty ?? false)
NOTIFICATION_LOCALIZATIONS: {
for (MapEntry<String, NotificationLocalization> localization
in _localizations!.entries)
localization.key: localization.value.toMap()
},
};