mirror of
https://github.com/dotnet/MQTTnet.git
synced 2026-10-16 01:03:01 +08:00
* Adds events for delivered and dropped messages. * Rename new events to match other namings * Update ReleaseNotes.md --------- Co-authored-by: Christian <6939810+chkr1011@users.noreply.github.com>
27 lines
1.1 KiB
C#
27 lines
1.1 KiB
C#
// Licensed to the .NET Foundation under one or more agreements.
|
|
// The .NET Foundation licenses this file to you under the MIT license.
|
|
// See the LICENSE file in the project root for more information.
|
|
|
|
using System;
|
|
|
|
namespace MQTTnet.Server
|
|
{
|
|
public sealed class ApplicationMessageEnqueuedEventArgs : EventArgs
|
|
{
|
|
public ApplicationMessageEnqueuedEventArgs(string senderClientId, string receiverClientId, MqttApplicationMessage applicationMessage, bool isDropped)
|
|
{
|
|
SenderClientId = senderClientId ?? throw new ArgumentNullException( nameof(senderClientId));
|
|
ReceiverClientId = receiverClientId ?? throw new ArgumentNullException(nameof(receiverClientId));
|
|
ApplicationMessage = applicationMessage ?? throw new ArgumentNullException(nameof(applicationMessage));
|
|
IsDropped = isDropped;
|
|
}
|
|
|
|
public string SenderClientId { get; }
|
|
|
|
public string ReceiverClientId { get; }
|
|
|
|
public bool IsDropped { get; }
|
|
|
|
public MqttApplicationMessage ApplicationMessage { get; }
|
|
}
|
|
} |