本文介绍了如何使用Swift在iOS应用中创建热点网络的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想使用Swift在iOS应用中创建一个热点网络.另外,请提出仅苹果批准的API.谢谢!

I want to create a hotspot network in iOS app using swift. Also please suggest ony apple approved APIs. Thanks!

推荐答案

NEHotspotHelper 是用于执行此类操作的官方API.尽管该API并非开放给所有人".它需要在应用程序中包含权利"com.apple.developer.networking.HotspotHelper".要使用此权利,您需要征求Apple的许可,以将此类与您的应用程序的包标识符一起使用,并明确说明了为什么需要此类以及其他一些应用程序详细信息.使用链接申请权利.苹果向您发送批准邮件后,您就可以使用了!

NEHotspotHelper is an official API to do exactly this kind of stuff. Though the API is not an 'Open to All' kind. It needs the entitlement 'com.apple.developer.networking.HotspotHelper' to be included in your app. To use this entitlement you need to ask for a permission from Apple to use this class with your app's bundle identifier with a clear reason for why you need it with some other details of your app. Use this link to apply for the entitlement. Once apple sends an approval mail to you, you are good to go!

这篇关于如何使用Swift在iOS应用中创建热点网络的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-12 13:49