0
A
回答
2
這是怎麼了,我終於做工作:
class ViewController: UIViewController ,SINCallClientDelegate, SINCallDelegate , SINClientDelegate{
@IBOutlet weak var callStatus: UILabel!
let sinchClient : SINClient = Sinch.clientWithApplicationKey("093f31d0-858a-4947-b29e-38bd5b2300c5", applicationSecret: "iBS+k7WmnUOfKr5w1wureg==", environmentHost: "sandbox.sinch.com", userId: "[email protected]")
var callClient : SINCallClient! ;
var call : SINCall! ;
var callClient : SINCallClient!;
override func viewDidLoad() {
super.viewDidLoad()
// Do any additional setup after loading the view, typically from a nib.
sinchClient.setSupportCalling(true)
sinchClient.start()
sinchClient.startListeningOnActiveConnection()
sinchClient.delegate = self
callClient = sinchClient.callClient()
}
func clientDidStart(client: SINClient!) {
print("Clien started")
}
func clientDidFail(client: SINClient!, error: NSError!) {
}
func clientDidStop(client: SINClient!) {
}
func client(client: SINClient!, logMessage message: String!, area: String!, severity: SINLogSeverity, timestamp: NSDate!) {
}
func callDidProgress(call: SINCall!) {
}
func callDidEstablish(call: SINCall!) {
callStatus.text = "Call Connected"
}
func callDidEnd(call: SINCall!) {
}
func client(client: SINCallClient!, didReceiveIncomingCall call: SINCall!) {
call.delegate = self;
call.answer()
}
override func didReceiveMemoryWarning() {
super.didReceiveMemoryWarning()
// Dispose of any resources that can be recreated.
}
@IBAction func callMike(sender: AnyObject) {
let call : SINCall = callClient.callUserWithId("[email protected]")
call.delegate = self
}
}
相關問題
- 1. 在註冊後,Sinch再次註冊了通知unregisterPushNotificationDeviceToken
- 2. 如何在didMoveToView(Swift,SpriteKit)中註冊touch?
- 3. 如何在沒有Cocoapods的情況下使用帶Swift項目的Sinch SDK
- 4. 如何恢復tuleap註冊項目
- 5. 如何註冊Google APis項目?
- 6. 在Windows安裝項目中註冊和取消註冊DLL
- 7. 在Swift中使用NSErrorPointer PARSE註冊
- 8. Sinch SDK - 如何註銷用戶?
- 9. 安裝項目COM註冊
- 10. 如何在Swift中將註冊用戶寫入數據庫?
- 11. netstandard1.6中的註冊表類; net46項目
- 12. 在swift 2.0中註冊/登錄錯誤
- 13. 在新的Firebase項目中使用相同的註冊用戶
- 14. 如何通過sinch和parse將消息廣播給所有註冊用戶?
- 15. 如何在Swift項目上使用BSKeyboardControls?
- 16. 如何修復我的新Laravel項目的用戶註冊?
- 17. 如何在Windows安裝項目中清理'啓動時運行'註冊表項?
- 18. 如何使用Swift 2註冊iOS 7中的遠程通知?
- 19. 如何在Swift 3中創建/註冊本地通知設置?
- 20. 如何在django項目中保存前端用戶登錄/註冊信息
- 21. 如何在Django中跨應用程序/項目註冊芹菜任務?
- 22. 使用Nant在註冊表中安裝項目
- 23. 使用web項目在程序集中註冊自定義類
- 24. 如何在C#中使用pinvoke regcreatekeyEx監視註冊表項?
- 25. facebook解析註冊swift
- 26. 如何在Sinch中禁用視頻
- 27. 如何在Firebase中註冊用戶名?
- 28. 註冊表項爲什麼/如何註冊表項在Regedit中隱藏但在PowerShell中可見?
- 29. 在Windows註冊表項頂部添加註冊表項#
- 30. 如何在swift的註冊頁面中強制使用用戶名
你可以添加一些代碼以及你正在嘗試做什麼 – cjensen