Android 3G / 2G governing API?

In the Android settings in the section "Wireless Controls" โ†’ "Mobile Networks" there is a parameter "Use only 2G networks."

In the Android SDK reference in the section android.telephony.TelephonyManager, it seems nothing is needed to control the type of network.

What APIs does this parameter actually call?

+3
source share
1 answer

It seems to be called com.android.internal.telephony.Phone.setPreferredNetworkType(). Since it is โ€œinternal,โ€ it is not available to applications through the SDK.

Cm:

https://android.googlesource.com/platform/packages/apps/Phone/+/master/src/com/android/phone/Use2GOnlyCheckBoxPreference.java

+6
source

Source: https://habr.com/ru/post/1732713/


All Articles