Ejemplo n.º 1
0
        public static async Task SendNotification(NotificationMessage notificationMessage)
        {
            CloudNotification cloudNotification = null;

            switch (notificationMessage.NotificationType)
            {
            case NotificationType.Email:
                cloudNotification = new EmailNotification();
                break;

            case NotificationType.Fcm:
                cloudNotification = new FcmNotification();
                break;
            }
            if (cloudNotification != null)
            {
                await cloudNotification.sendNotification(notificationMessage);
            }
        }
Ejemplo n.º 2
0
 public EmailService(CloudNotification cloudNotification)
 {
     this.cloudNotification = cloudNotification;
 }