Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/ios/104.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Ios 由于使用即时消息发送推送通知_Ios_Xcode_Apple Push Notifications_Sinch - Fatal编程技术网

Ios 由于使用即时消息发送推送通知

Ios 由于使用即时消息发送推送通知,ios,xcode,apple-push-notifications,sinch,Ios,Xcode,Apple Push Notifications,Sinch,我正在使用SinMessageClient发送消息。我需要在我的代码中支持推送通知,我已使用以下代码设置推送: NSString* userId = [options valueForKey:APP_USER_USERID_CONSTANT]; id<SINClient> sinchClient = [Sinch clientWithApplicationKey:SINCH_AP

我正在使用SinMessageClient发送消息。我需要在我的代码中支持推送通知,我已使用以下代码设置推送:

NSString* userId = [options valueForKey:APP_USER_USERID_CONSTANT];
            id<SINClient> sinchClient = [Sinch
                                         clientWithApplicationKey:SINCH_APPLICATION_KEY
                                          applicationSecret:SINCH_APPLICATION_SECRET
                                                environmentHost:@"sandbox.sinch.com"
                                                                 userId:userId];
            [sinchClient setSupportMessaging:YES];
            [sinchClient enableManagedPushNotifications];
            sinchClient.delegate = delegate;
            self.push = [Sinch managedPushWithAPSEnvironment:SINAPSEnvironmentAutomatic];
            self.push.delegate = delegate;
            [self.push setDesiredPushTypeAutomatically];
            [self.push registerUserNotificationSettings];
            // Start the Sinch Client
            [sinchClient start];
            // Start listening for incoming events (calls and messages).
            [sinchClient startListeningOnActiveConnection];
NSString*userId=[options valueForKey:APP\u USER\u userId\u CONSTANT];
id sinchClient=[Sinch
具有应用程序密钥的客户端:SINCH_应用程序密钥
应用机密:SINCH_应用机密
环境主机:@“sandbox.sinch.com”
userId:userId];
[sinchClient setSupportMessaging:是];
[sinchClient enableManagedPushNotifications];
sinchClient.delegate=委托;
self.push=[Sinch managedPushWithAPSEnvironment:SinapsEnvironment Automatic];
self.push.delegate=委托;
[自推设置DesiredPushTypeAutomatically];
[self.push注册表通知设置];
//启动Sinch客户端
[sinchClient start];
//开始监听传入事件(呼叫和消息)。
[sinchClient startListeningOnActiveConnection];
我还实现了这里提到的所有需求

它不工作,我有以下疑问。 如果我的应用程序在后台,如何发送推送消息? 我可以在不支持sinch呼叫客户端的情况下支持推送通知吗?
我在sinch仪表板上只上传了APN推送证书,没有voip推送证书。它是否适用于即时消息应用程序?

常规推送工作,无需呼叫客户端。您仍然有问题吗?

定期推送工作,不需要callClient。你还有问题吗?

我被类似的问题缠住了。我被类似的问题缠住了。我也没有得到任何帮助。你能帮忙吗?我也没有得到任何推动。你能帮忙吗?