showNotificationCustomTemplate method

  1. @override
Future<void> showNotificationCustomTemplate(
  1. NotificationMessage notification,
  2. String? applicationId,
  3. String template
)
override

Implementation

@override
Future<void> showNotificationCustomTemplate(
    final NotificationMessage notification,
    final String? applicationId,
    final String template) async {
  assert(notification.temolateType == TemplateType.custom,
      "Use NotificationMessage.fromCustomTemplate to create notification object");
  final data = notification.toJson;
  if (applicationId != null) data["application_id"] = applicationId;
  data["template"] = template;
  await methodChannel.invokeMethod(notification.methodNmae, data);
}