summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Remi NGUYEN VAN <reminv@google.com> 2020-11-30 19:23:45 +0900
committer Remi NGUYEN VAN <reminv@google.com> 2020-11-30 19:23:45 +0900
commit7f159cf6401fe76cc1e8d89124f83228c9a7994a (patch)
tree974e23b049dbee325b64759b2f8e0b05d3c76d49
parent540826860636597c634fc8c991d22b97d893bdbc (diff)
Add ConnectivityManager.TYPE_PROXY to SystemApi
This follows other TYPE_* constants like TYPE_WIFI_P2P that are @SystemApi or public. TYPE_PROXY has a use-case for the system to set network policies based on proxy network templates. Although network types are deprecated, that use-case needs to be supported and significant amounts of network management would need to be rewritten to stop using network types. The constant needs to be API as ConnectivityManager is planned to move out of framework.jar, so only its formal API will be available to the system server. Bug: 174436414 Test: m Change-Id: I266ed6bc59f5eb72302afe14472c93933733c8f8
-rw-r--r--core/api/system-current.txt1
-rw-r--r--core/java/android/net/ConnectivityManager.java2
2 files changed, 2 insertions, 1 deletions
diff --git a/core/api/system-current.txt b/core/api/system-current.txt
index f6b1d0627312..7090ebe901a4 100644
--- a/core/api/system-current.txt
+++ b/core/api/system-current.txt
@@ -5986,6 +5986,7 @@ package android.net {
field @Deprecated public static final int TETHER_ERROR_NO_ERROR = 0; // 0x0
field @Deprecated public static final int TETHER_ERROR_PROVISION_FAILED = 11; // 0xb
field public static final int TYPE_NONE = -1; // 0xffffffff
+ field @Deprecated public static final int TYPE_PROXY = 16; // 0x10
field @Deprecated public static final int TYPE_WIFI_P2P = 13; // 0xd
}
diff --git a/core/java/android/net/ConnectivityManager.java b/core/java/android/net/ConnectivityManager.java
index c28a901fba75..cf5d4e579f85 100644
--- a/core/java/android/net/ConnectivityManager.java
+++ b/core/java/android/net/ConnectivityManager.java
@@ -684,7 +684,7 @@ public class ConnectivityManager {
* {@hide}
*/
@Deprecated
- @UnsupportedAppUsage
+ @SystemApi
public static final int TYPE_PROXY = 16;
/**