mirror of
https://github.com/dotnet/MQTTnet.git
synced 2026-10-17 01:33:03 +08:00
27 lines
986 B
C#
27 lines
986 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace MQTTnet.Server
|
|
{
|
|
public interface IMqttServer : IApplicationMessageReceiver, IApplicationMessagePublisher
|
|
{
|
|
event EventHandler Started;
|
|
event EventHandler Stopped;
|
|
|
|
event EventHandler<MqttClientConnectedEventArgs> ClientConnected;
|
|
event EventHandler<MqttClientDisconnectedEventArgs> ClientDisconnected;
|
|
event EventHandler<MqttClientSubscribedTopicEventArgs> ClientSubscribedTopic;
|
|
event EventHandler<MqttClientUnsubscribedTopicEventArgs> ClientUnsubscribedTopic;
|
|
|
|
IMqttServerOptions Options { get; }
|
|
|
|
Task<IList<IMqttClientSessionStatus>> GetClientSessionsStatusAsync();
|
|
|
|
Task SubscribeAsync(string clientId, IList<TopicFilter> topicFilters);
|
|
Task UnsubscribeAsync(string clientId, IList<string> topicFilters);
|
|
|
|
Task StartAsync(IMqttServerOptions options);
|
|
Task StopAsync();
|
|
}
|
|
} |