Browse Source

增加退订主题

DGJ 8 months ago
parent
commit
8a49e67796
1 changed files with 9 additions and 1 deletions
  1. 9 1
      package/Runtime/MQTT/1.0.0/GHZMQTT/QTTManager.cs

+ 9 - 1
package/Runtime/MQTT/1.0.0/GHZMQTT/QTTManager.cs

@@ -77,7 +77,15 @@ public class QTTManager
     {
         return client.Subscribe(topics, qosLevels);
     }
-
+    /// <summary>
+    ///  退订主题
+    /// </summary>
+    /// <param name="topics"></param>
+    /// <returns></returns>
+    public ushort Unsubscribe(string[] topics)
+    {
+        return client.Unsubscribe(topics);
+    }
     public Action OnConnecting;
     /// <summary>
     /// 使用当前设置连接到代理。