using MediaBrowser.Model.Notifications; using System; using System.Collections.Generic; using System.Threading; using System.Threading.Tasks; namespace MediaBrowser.Controller.Notifications { /// /// Interface INotificationsRepository /// public interface INotificationsRepository { /// /// Occurs when [notification added]. /// event EventHandler NotificationAdded; /// /// Occurs when [notifications marked read]. /// event EventHandler NotificationsMarkedRead; /// /// Gets the notifications. /// /// The query. /// NotificationResult. NotificationResult GetNotifications(NotificationQuery query); /// /// Adds the notification. /// /// The notification. /// The cancellation token. /// Task. Task AddNotification(Notification notification, CancellationToken cancellationToken); /// /// Marks the read. /// /// The notification id list. /// The user id. /// if set to true [is read]. /// The cancellation token. /// Task. Task MarkRead(IEnumerable notificationIdList, string userId, bool isRead, CancellationToken cancellationToken); /// /// Marks all read. /// /// The user identifier. /// if set to true [is read]. /// The cancellation token. /// Task. Task MarkAllRead(string userId, bool isRead, CancellationToken cancellationToken); /// /// Gets the notifications summary. /// /// The user id. /// NotificationsSummary. NotificationsSummary GetNotificationsSummary(string userId); } }