Re-hide onPreCheck and unhide NET_CAPABILITY_VALIDATED.

The API review comments in http://b/21343774 point out that the
suggested use case for onPreCheck (captive portal login apps) is
not a good use case as it requires that the app always be
running.

Also, unhide NET_CAPABILITY_VALIDATED, which is useful to apps
that want to detect captive portals and network connectivity
failures.

Bug: 21343774
Change-Id: Iad7c839bcc136b0fa9581dccc5fd97a28efed4ab
This commit is contained in:
Lorenzo Colitti
2015-06-11 14:27:17 +09:00
parent ddb3d3aacc
commit 3a9df1a8cd
2 changed files with 2 additions and 1 deletions

View File

@@ -2162,6 +2162,8 @@ public class ConnectivityManager {
* can automatically log in to a captive portal without user intervention.
*
* @param network The {@link Network} of the network that is being evaluated.
*
* @hide
*/
public void onPreCheck(Network network) {}

View File

@@ -173,7 +173,6 @@ public final class NetworkCapabilities implements Parcelable {
* Indicates that connectivity on this network was successfully validated. For example, for a
* network with NET_CAPABILITY_INTERNET, it means that Internet connectivity was successfully
* detected.
* @hide
*/
public static final int NET_CAPABILITY_VALIDATED = 16;