You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

27 lines
817 B

  1. using System;
  2. using MQTTnet.Core.Serializer;
  3. namespace MQTTnet.Core.Client
  4. {
  5. public abstract class BaseMqttClientOptions : IMqttClientOptions
  6. {
  7. public MqttClientTlsOptions TlsOptions { get; set; } = new MqttClientTlsOptions();
  8. public MqttApplicationMessage WillMessage { get; set; }
  9. public string UserName { get; set; }
  10. public string Password { get; set; }
  11. public string ClientId { get; set; } = Guid.NewGuid().ToString("N");
  12. public bool CleanSession { get; set; } = true;
  13. public TimeSpan KeepAlivePeriod { get; set; } = TimeSpan.FromSeconds(5);
  14. public TimeSpan DefaultCommunicationTimeout { get; set; } = TimeSpan.FromSeconds(10);
  15. public MqttProtocolVersion ProtocolVersion { get; set; } = MqttProtocolVersion.V311;
  16. }
  17. }