Class NotificationState
- Namespace
- SharpConsoleUI.Core
- Assembly
- SharpConsoleUI.dll
Represents the current notification system state.
public record NotificationState : IEquatable<NotificationState>
- Inheritance
-
NotificationState
- Implements
- Inherited Members
Constructors
NotificationState(IReadOnlyList<NotificationInfo>, int, int)
Represents the current notification system state.
public NotificationState(IReadOnlyList<NotificationInfo> ActiveNotifications, int TotalShown, int TotalDismissed)
Parameters
ActiveNotificationsIReadOnlyList<NotificationInfo>The list of currently active notifications.
TotalShownintThe total number of notifications shown since service creation.
TotalDismissedintThe total number of notifications dismissed since service creation.
Properties
ActiveCount
Gets the number of active notifications.
public int ActiveCount { get; }
Property Value
ActiveNotifications
The list of currently active notifications.
public IReadOnlyList<NotificationInfo> ActiveNotifications { get; init; }
Property Value
Empty
Gets an empty notification state.
public static NotificationState Empty { get; }
Property Value
HasNotifications
Gets a value indicating whether there are any active notifications.
public bool HasNotifications { get; }
Property Value
TotalDismissed
The total number of notifications dismissed since service creation.
public int TotalDismissed { get; init; }
Property Value
TotalShown
The total number of notifications shown since service creation.
public int TotalShown { get; init; }