Multiple choice technology platforms and products

To get more details on available active networks, you may call following method(s) in Android

  1. getNetworkInfo()

  2. getNetworkStatus()

  3. getActiveNetworkInfo()

  4. Both, a & b above

  5. Both a & c above

  6. All of above

Reveal answer Fill a bubble to check yourself
E Correct answer
Explanation

getNetworkInfo() and getActiveNetworkInfo() are both valid ConnectivityManager methods for retrieving network details. getNetworkStatus() is not a standard Android API method. Both getNetworkInfo() (deprecated) and getActiveNetworkInfo() provide information about network state and connectivity.