|
1234567891011121314151617181920212223242526 |
- using System;
- using System.Collections.Generic;
- using System.Threading.Tasks;
-
- namespace MQTTnet.Server
- {
- public interface IMqttServer : IApplicationMessageReceiver, IApplicationMessagePublisher
- {
- event EventHandler<MqttServerStartedEventArgs> Started;
-
- event EventHandler<MqttClientConnectedEventArgs> ClientConnected;
- event EventHandler<MqttClientDisconnectedEventArgs> ClientDisconnected;
- event EventHandler<MqttClientSubscribedTopicEventArgs> ClientSubscribedTopic;
- event EventHandler<MqttClientUnsubscribedTopicEventArgs> ClientUnsubscribedTopic;
-
- IMqttServerOptions Options { get; }
-
- Task<IList<ConnectedMqttClient>> GetConnectedClientsAsync();
-
- Task SubscribeAsync(string clientId, IList<TopicFilter> topicFilters);
- Task UnsubscribeAsync(string clientId, IList<string> topicFilters);
-
- Task StartAsync(IMqttServerOptions options);
- Task StopAsync();
- }
- }
|