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.
 
 
 
 

28 regels
771 B

  1. using MQTTnet.Protocol;
  2. namespace MQTTnet.Packets
  3. {
  4. public sealed class MqttPublishPacket : MqttBasePublishPacket
  5. {
  6. public bool Retain { get; set; }
  7. public MqttQualityOfServiceLevel QualityOfServiceLevel { get; set; }
  8. public bool Dup { get; set; }
  9. public string Topic { get; set; }
  10. public byte[] Payload { get; set; }
  11. public override string ToString()
  12. {
  13. return "Publish: [Topic=" + Topic + "]" +
  14. " [Payload.Length=" + Payload?.Length + "]" +
  15. " [QoSLevel=" + QualityOfServiceLevel + "]" +
  16. " [Dup=" + Dup + "]" +
  17. " [Retain=" + Retain + "]" +
  18. " [PacketIdentifier=" + PacketIdentifier + "]";
  19. }
  20. }
  21. }