What is the difference between access network states (ACCESS_NETWORK_STATE) and WIFI (ACCESS_WIFI_STATE)?

On the Permissions tab in the Android manifest, the android.permission.ACCESS_NETWORK_STATE and android.permission.ACCESS_WIFI_STATE options are in the drop-down list. What is the difference between the two? Is ACCESS_NETWORK_STATE more general than ACCESS_WIFI_STATE ?

+54
android android-permissions android-manifest
Feb 27 2018-12-12T00:
source share
2 answers

android.permission.ACCESS_NETWORK_STATE needed to access the ConnectivityManager (mainly for monitoring network connections in general), and android.permission.ACCESS_WIFI_STATE provides access to the WifiManager (to manage all aspects of Wi-Fi connection in particular).

+42
Feb 27 '12 at 1:05
source share

Network status refers to a cellular network connection.

Wifi status refers to the Wifi connection status of the phone.

0
Feb 27 2018-12-12T00:
source share



All Articles