|
1234567891011121314151617181920212223 |
- using System;
- using System.Collections.Generic;
- using System.Threading;
- using System.Threading.Tasks;
- using MQTTnet.Core.Client;
- using MQTTnet.Core.Packets;
- using MQTTnet.Core.Serializer;
-
- namespace MQTTnet.Core.Adapter
- {
- public interface IMqttCommunicationAdapter
- {
- IMqttPacketSerializer PacketSerializer { get; }
-
- Task ConnectAsync(TimeSpan timeout, MqttClientOptions options);
-
- Task DisconnectAsync(TimeSpan timeout);
-
- Task SendPacketsAsync(TimeSpan timeout, CancellationToken cancellationToken, IEnumerable<MqttBasePacket> packets);
-
- Task<MqttBasePacket> ReceivePacketAsync(TimeSpan timeout, CancellationToken cancellationToken);
- }
- }
|