using ScadaLink.Commons.Types.Enums; namespace ScadaLink.Commons.Messages.Streaming; public record AlarmStateChanged( string InstanceUniqueName, string AlarmName, AlarmState State, int Priority, DateTimeOffset Timestamp) { /// /// Severity level when is . /// Always for binary trigger types /// (ValueMatch, RangeViolation, RateOfChange); set by the HiLo trigger /// type to one of Low/LowLow/High/HighHigh based on the crossed setpoint. /// Added as an init-property so existing positional constructors still /// work — message contract evolves additively. /// public AlarmLevel Level { get; init; } = AlarmLevel.None; /// /// Optional per-band operator message (e.g., "Coolant critically low — /// shut down"). Set by HiLo triggers when the per-setpoint message is /// configured; otherwise empty. Notification routing and UI tooltips may /// surface this to operators. /// public string Message { get; init; } = string.Empty; }