OfflinePushInfoConfig.swift 1.1 KB

1234567891011121314151617181920212223242526272829
  1. //
  2. // OfflinePushInfoConfig.swift
  3. // TUICallKit
  4. //
  5. // Created by vincepzhang on 2023/1/6.
  6. //
  7. import Foundation
  8. import TUICallEngine
  9. @objc
  10. public class OfflinePushInfoConfig: NSObject {
  11. @objc
  12. public static func createOfflinePushInfo() -> TUIOfflinePushInfo {
  13. let pushInfo: TUIOfflinePushInfo = TUIOfflinePushInfo()
  14. pushInfo.title = ""
  15. pushInfo.desc = TUICallKitLocalize(key: "TUICallKit.have.new.invitation") ?? ""
  16. // iOS push type: if you want user VoIP, please modify type to TUICallIOSOfflinePushTypeVoIP
  17. pushInfo.iOSPushType = .apns
  18. pushInfo.ignoreIOSBadge = false
  19. pushInfo.iOSSound = "phone_ringing.mp3"
  20. pushInfo.androidSound = "phone_ringing"
  21. // VIVO message type: 0-push message, 1-System message(have a higher delivery rate)
  22. pushInfo.androidVIVOClassification = 1
  23. // HuaWei message type: https://developer.huawei.com/consumer/cn/doc/development/HMSCore-Guides/message-classification-0000001149358835
  24. pushInfo.androidHuaWeiCategory = "IM"
  25. return pushInfo
  26. }
  27. }