你可以用你的声音回答推送通知吗?因此,当您锁定iPhone并获得推送通知时,您是否可以用语音对其做出反应?
答案 0 :(得分:0)
您尚未在应用中注册音频推送通知。只需在App Delegate中注册它:
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
//Whatever you have already in your app delegate...
// Let device know you're going to be sending one of these types of notifications.
[[UIApplication sharedApplication] registerForRemoteNotificationTypes:
(UIRemoteNotificationTypeBadge | UIRemoteNotificationTypeSound | UIRemoteNotificationTypeAlert)];
return YES;
}
这5种类型是:
以下是文档:Registering for Remote Notifications
也引用此documents
希望有所帮助!
答案 1 :(得分:-1)
您无法在推送通知中播放语音。推送通知有效负载不包含您的语音。 用户通过以下方式查看通知:
根据苹果推送通知文件