5

Is it possible to determine which kind of network is on the device when the user is interacting with my app?

Right now I have the Reachability class and I can differentiate between Wi-Fi and Cellular, but how to check if the Cellular is LTE, 3G, HSPA, EDGE?

4

2 回答 2

0

目前没有办法区分不同类型的蜂窝网络。

有关更多信息,请参阅此问题。

于 2012-12-04T09:44:06.557 回答
0

从 iOS7 开始,可以使用 CTTelephonyNetworkInfo() 获得有关蜂窝连接的信息:

let info = CTTelephonyNetworkInfo()
print(“carrierName": " + "\(info.subscriberCellularProvider?.carrierName ?? "Has not been configured for carrier")")
print(“currentRadioAccessTechnology: " + "\(info.currentRadioAccessTechnology ?? "Airplane Mode/No cell connection")")

currentRadioAccessTechnology 将显示一个描述连接类型的字符串。

于 2018-01-09T01:22:25.853 回答