diff options
Diffstat (limited to 'connectivity/network/BasicNetworking/README.md')
-rw-r--r-- | connectivity/network/BasicNetworking/README.md | 29 |
1 files changed, 23 insertions, 6 deletions
diff --git a/connectivity/network/BasicNetworking/README.md b/connectivity/network/BasicNetworking/README.md index 03509175..d95f2962 100644 --- a/connectivity/network/BasicNetworking/README.md +++ b/connectivity/network/BasicNetworking/README.md @@ -1,19 +1,36 @@ + Android BasicNetworking Sample -============================== +=================================== + +This sample demonstrates how to check network connectivity with Android APIs. -This sample demonstrates how to use the ConnectivityManager to determine if you have +Introduction +------------ + +It utilizes the [`ConnectivityManager`][1] to determine if you have a network connection, and if so, what type of connection it is. -A "NetworkInfo" object is retrieved from the ConnectivityManager, which contains information +A [`NetworkInfo`][2] object is retrieved from the ConnectivityManager, which contains information on the active connection, and then the connection type is printed to an on-screen console. +Multiple types of connectivity can be displayed and could be used to take different measures +in actual production code. + +[1]: https://developer.android.com/reference/android/net/ConnectivityManager.html +[2]: https://developer.android.com/reference/android/net/NetworkInfo.html + Pre-requisites -------------- -- Android SDK v20 -- Android Build Tools v20 +- Android SDK v23 +- Android Build Tools v22.0.1 - Android Support Repository +Screenshots +------------- + +<img src="screenshots/start.png" height="400" alt="Screenshot"/> <img src="screenshots/tested.png" height="400" alt="Screenshot"/> + Getting Started --------------- @@ -44,7 +61,7 @@ file to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at - http://www.apache.org/licenses/LICENSE-2.0 +http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT |