25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

MqttSubscribePacket.cs 654 B

123456789101112131415161718
  1. using System.Collections.Generic;
  2. using System.Linq;
  3. namespace MQTTnet.Core.Packets
  4. {
  5. public sealed class MqttSubscribePacket : MqttBasePacket, IMqttPacketWithIdentifier
  6. {
  7. public ushort PacketIdentifier { get; set; }
  8. public IList<TopicFilter> TopicFilters { get; set; } = new List<TopicFilter>();
  9. public override string ToString()
  10. {
  11. var topicFiltersText = string.Join(",", TopicFilters.Select(f => $"{f.Topic}@{f.QualityOfServiceLevel}"));
  12. return nameof(MqttSubscribePacket) + ": [PacketIdentifier=" + PacketIdentifier + "] [TopicFilters=" + topicFiltersText + "]";
  13. }
  14. }
  15. }