- Both of iPad and iPhone.
- Sample Code:
// AppDelegate.swift
let sharedInstance = Zoom() // this is a singleton
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
sharedInstance.auth()
}
/// Zoom.swift
class Zoom: NSObject {
private func auth() {
#if !arch(x86_64)
MobileRTC.shared().setMobileRTCDomain(API.domain)
let service = MobileRTC.shared().getAuthService()
if service != nil {
service?.clientKey = API.key
service?.clientSecret = API.secret
service?.delegate = self
service?.sdkAuth()
}
#endif
}
}
#if !arch(x86_64)
extension Zoom: MobileRTCAuthDelegate, MobileRTCMeetingServiceDelegate {
func onMobileRTCAuthReturn(_ returnValue: MobileRTCAuthError) {
switch returnValue {
case MobileRTCAuthError_Success:
MobileRTC.shared()?.getMeetingService()?.delegate = self
default:
break
}
}
///...
}
#endif
...