Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 66276122 authored by Lorenzo Colitti's avatar Lorenzo Colitti
Browse files

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
parent 40dbedfb
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -18209,7 +18209,6 @@ package android.net {
    method public void onLinkPropertiesChanged(android.net.Network, android.net.LinkProperties);
    method public void onLosing(android.net.Network, int);
    method public void onLost(android.net.Network);
    method public void onPreCheck(android.net.Network);
  }
  public static abstract interface ConnectivityManager.OnNetworkActiveListener {
@@ -18374,6 +18373,7 @@ package android.net {
    field public static final int NET_CAPABILITY_RCS = 8; // 0x8
    field public static final int NET_CAPABILITY_SUPL = 1; // 0x1
    field public static final int NET_CAPABILITY_TRUSTED = 14; // 0xe
    field public static final int NET_CAPABILITY_VALIDATED = 16; // 0x10
    field public static final int NET_CAPABILITY_WIFI_P2P = 6; // 0x6
    field public static final int NET_CAPABILITY_XCAP = 9; // 0x9
    field public static final int TRANSPORT_BLUETOOTH = 2; // 0x2
+1 −1
Original line number Diff line number Diff line
@@ -19697,7 +19697,6 @@ package android.net {
    method public void onLinkPropertiesChanged(android.net.Network, android.net.LinkProperties);
    method public void onLosing(android.net.Network, int);
    method public void onLost(android.net.Network);
    method public void onPreCheck(android.net.Network);
  }
  public static abstract interface ConnectivityManager.OnNetworkActiveListener {
@@ -19862,6 +19861,7 @@ package android.net {
    field public static final int NET_CAPABILITY_RCS = 8; // 0x8
    field public static final int NET_CAPABILITY_SUPL = 1; // 0x1
    field public static final int NET_CAPABILITY_TRUSTED = 14; // 0xe
    field public static final int NET_CAPABILITY_VALIDATED = 16; // 0x10
    field public static final int NET_CAPABILITY_WIFI_P2P = 6; // 0x6
    field public static final int NET_CAPABILITY_XCAP = 9; // 0x9
    field public static final int TRANSPORT_BLUETOOTH = 2; // 0x2
+2 −0
Original line number Diff line number Diff line
@@ -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) {}

+0 −1
Original line number Diff line number Diff line
@@ -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;