blob: 23a71798d7c6217b3895ce26c59a8dd192a28fa9 [file] [log] [blame]
Remi NGUYEN VANf15fc7f2021-01-28 13:37:03 +09001// Signature format: 2.0
2package android.net {
3
4 public final class ConnectivityFrameworkInitializer {
5 method public static void registerServiceWrappers();
6 }
7
8 public class ConnectivityManager {
Chiachang Wangf9294e72021-03-18 09:44:34 +08009 method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public void factoryReset();
junyulaib1211372021-03-03 12:09:05 +080010 method @NonNull @RequiresPermission(anyOf={android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK, android.Manifest.permission.NETWORK_STACK, android.Manifest.permission.NETWORK_SETTINGS}) public java.util.List<android.net.NetworkStateSnapshot> getAllNetworkStateSnapshot();
Chiachang Wangf9294e72021-03-18 09:44:34 +080011 method @Nullable public android.net.ProxyInfo getGlobalProxy();
lucaslin5cdbcfb2021-03-12 00:46:33 +080012 method @NonNull public static android.util.Range<java.lang.Integer> getIpSecNetIdRange();
lucasline2cd02d2021-03-16 17:11:14 +080013 method @NonNull public static String getPrivateDnsMode(@NonNull android.content.Context);
Lorenzo Colittib90bdbd2021-03-22 18:23:21 +090014 method @RequiresPermission(anyOf={android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK, android.Manifest.permission.NETWORK_SETTINGS}) public void registerDefaultNetworkCallbackAsUid(int, @NonNull android.net.ConnectivityManager.NetworkCallback, @NonNull android.os.Handler);
Remi NGUYEN VANf15fc7f2021-01-28 13:37:03 +090015 method @RequiresPermission(anyOf={android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK, android.Manifest.permission.NETWORK_SETTINGS}) public void registerSystemDefaultNetworkCallback(@NonNull android.net.ConnectivityManager.NetworkCallback, @NonNull android.os.Handler);
junyulaidbb70462021-03-09 20:49:48 +080016 method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_STACK, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public void requestBackgroundNetwork(@NonNull android.net.NetworkRequest, @NonNull android.os.Handler, @NonNull android.net.ConnectivityManager.NetworkCallback);
Chiachang Wangf9294e72021-03-18 09:44:34 +080017 method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD, android.Manifest.permission.NETWORK_STACK, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public void setAcceptPartialConnectivity(@NonNull android.net.Network, boolean, boolean);
18 method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD, android.Manifest.permission.NETWORK_STACK, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public void setAcceptUnvalidated(@NonNull android.net.Network, boolean, boolean);
19 method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD, android.Manifest.permission.NETWORK_STACK, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public void setAvoidUnvalidated(@NonNull android.net.Network);
20 method @RequiresPermission(android.Manifest.permission.NETWORK_STACK) public void setGlobalProxy(@Nullable android.net.ProxyInfo);
Chalard Jean0a4aefc2021-03-03 16:37:13 +090021 method @RequiresPermission(android.Manifest.permission.NETWORK_STACK) public void setProfileNetworkPreference(@NonNull android.os.UserHandle, int, @Nullable java.util.concurrent.Executor, @Nullable Runnable);
Remi NGUYEN VANf15fc7f2021-01-28 13:37:03 +090022 method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_TEST_NETWORKS, android.Manifest.permission.NETWORK_STACK}) public void simulateDataStall(int, long, @NonNull android.net.Network, @NonNull android.os.PersistableBundle);
Remi NGUYEN VAN8238a762021-03-16 18:06:06 +090023 method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_STACK, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public void startCaptivePortalApp(@NonNull android.net.Network);
lucaslin10774b72021-03-17 14:16:01 +080024 method public void systemReady();
lucaslin889dcda2021-03-12 17:56:09 +080025 field public static final String PRIVATE_DNS_MODE_OFF = "off";
26 field public static final String PRIVATE_DNS_MODE_OPPORTUNISTIC = "opportunistic";
27 field public static final String PRIVATE_DNS_MODE_PROVIDER_HOSTNAME = "hostname";
Chalard Jeanbef6b092021-03-17 14:33:24 +090028 field public static final int PROFILE_NETWORK_PREFERENCE_DEFAULT = 0; // 0x0
29 field public static final int PROFILE_NETWORK_PREFERENCE_ENTERPRISE = 1; // 0x1
Remi NGUYEN VANf15fc7f2021-01-28 13:37:03 +090030 }
31
32 public final class NetworkAgentConfig implements android.os.Parcelable {
33 method @Nullable public String getSubscriberId();
lucaslin0e345e92021-03-22 15:07:41 +080034 method public boolean isBypassableVpn();
Remi NGUYEN VANf15fc7f2021-01-28 13:37:03 +090035 }
36
37 public static final class NetworkAgentConfig.Builder {
lucaslin0e345e92021-03-22 15:07:41 +080038 method @NonNull public android.net.NetworkAgentConfig.Builder setBypassableVpn(boolean);
Remi NGUYEN VANf15fc7f2021-01-28 13:37:03 +090039 method @NonNull public android.net.NetworkAgentConfig.Builder setSubscriberId(@Nullable String);
40 }
41
42 public final class NetworkCapabilities implements android.os.Parcelable {
Roshan Piuse2d28382021-02-23 08:47:39 -080043 ctor public NetworkCapabilities(@Nullable android.net.NetworkCapabilities, long);
Chiachang Wang628cb112021-03-19 00:45:39 +000044 method @Nullable public java.util.Set<android.util.Range<java.lang.Integer>> getUids();
Roshan Piuse2d28382021-02-23 08:47:39 -080045 field public static final long REDACT_ALL = -1L; // 0xffffffffffffffffL
46 field public static final long REDACT_FOR_ACCESS_FINE_LOCATION = 1L; // 0x1L
47 field public static final long REDACT_FOR_LOCAL_MAC_ADDRESS = 2L; // 0x2L
48 field public static final long REDACT_FOR_NETWORK_SETTINGS = 4L; // 0x4L
49 field public static final long REDACT_NONE = 0L; // 0x0L
Remi NGUYEN VANf15fc7f2021-01-28 13:37:03 +090050 field public static final int TRANSPORT_TEST = 7; // 0x7
51 }
52
Chiachang Wang628cb112021-03-19 00:45:39 +000053 public static final class NetworkCapabilities.Builder {
54 method @NonNull public android.net.NetworkCapabilities.Builder setUids(@Nullable java.util.Set<android.util.Range<java.lang.Integer>>);
55 }
56
57 public static class NetworkRequest.Builder {
58 method @NonNull public android.net.NetworkRequest.Builder setUids(@Nullable java.util.Set<android.util.Range<java.lang.Integer>>);
59 }
60
Remi NGUYEN VAN25dcabf2021-03-15 10:20:40 +090061 public class ParseException extends java.lang.RuntimeException {
62 ctor public ParseException(@NonNull String);
63 ctor public ParseException(@NonNull String, @NonNull Throwable);
64 }
65
Remi NGUYEN VANf15fc7f2021-01-28 13:37:03 +090066 public final class TcpRepairWindow {
67 ctor public TcpRepairWindow(int, int, int, int, int, int);
68 field public final int maxWindow;
69 field public final int rcvWnd;
70 field public final int rcvWndScale;
71 field public final int rcvWup;
72 field public final int sndWl1;
73 field public final int sndWnd;
74 }
75
76 public final class TestNetworkInterface implements android.os.Parcelable {
77 ctor public TestNetworkInterface(@NonNull android.os.ParcelFileDescriptor, @NonNull String);
78 method public int describeContents();
79 method @NonNull public android.os.ParcelFileDescriptor getFileDescriptor();
80 method @NonNull public String getInterfaceName();
81 method public void writeToParcel(@NonNull android.os.Parcel, int);
82 field @NonNull public static final android.os.Parcelable.Creator<android.net.TestNetworkInterface> CREATOR;
83 }
84
85 public class TestNetworkManager {
86 method @NonNull public android.net.TestNetworkInterface createTapInterface();
87 method @NonNull public android.net.TestNetworkInterface createTunInterface(@NonNull java.util.Collection<android.net.LinkAddress>);
88 method public void setupTestNetwork(@NonNull String, @NonNull android.os.IBinder);
89 method public void teardownTestNetwork(@NonNull android.net.Network);
90 field public static final String TEST_TAP_PREFIX = "testtap";
91 }
92
Remi NGUYEN VANea33ac92021-02-04 14:20:19 +090093 public final class TestNetworkSpecifier extends android.net.NetworkSpecifier implements android.os.Parcelable {
94 ctor public TestNetworkSpecifier(@NonNull String);
95 method public int describeContents();
96 method @Nullable public String getInterfaceName();
97 method public void writeToParcel(@NonNull android.os.Parcel, int);
98 field @NonNull public static final android.os.Parcelable.Creator<android.net.TestNetworkSpecifier> CREATOR;
99 }
100
Roshan Piuse2d28382021-02-23 08:47:39 -0800101 public interface TransportInfo {
102 method public default long getApplicableRedactions();
103 method @NonNull public default android.net.TransportInfo makeCopy(long);
104 }
105
Remi NGUYEN VANf15fc7f2021-01-28 13:37:03 +0900106 public final class VpnTransportInfo implements android.os.Parcelable android.net.TransportInfo {
107 ctor public VpnTransportInfo(int);
108 method public int describeContents();
109 method public void writeToParcel(@NonNull android.os.Parcel, int);
110 field @NonNull public static final android.os.Parcelable.Creator<android.net.VpnTransportInfo> CREATOR;
111 field public final int type;
112 }
113
114}
115