实现了,我正在考虑使用静音推送通知.所以我想要
确认设备何时收到它,以及我可以做什么?
解决方法
>下载一些内容
>同步一些元素,
>当应用程序打开时,直接通知用户
请注意,您的时间限制在30秒.
配置静默通知
To support silent remote notifications,add the remote-notification value to the UIBackgroundModes array in your Info.plist file. To learn more about this array,see UIBackgroundModes.
<key>UIBackgroundModes</key> <array> <string>remote-notification</string> </array>
Configuring a Silent Notification
The aps dictionary can also contain the content-available property. The content- available property with a value of 1 lets the remote notification act as a silent notification. When a silent notification arrives,iOS wakes up your app in the background so that you can get new data from your server or do background information processing. Users aren’t told about the new or changed information that results from a silent notification,but they can find out about it the next time they open your app.
For a silent notification,take care to ensure there is no alert,sound,or badge payload in the aps dictionary. If you don’t follow this guidance,the incorrectly-configured notification might be throttled and not delivered to the app in the background,and instead of being silent is displayed to the user
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。