From f5df095388b041db49114f1b43b0984e9153eb99 Mon Sep 17 00:00:00 2001 From: Joshua Mccloskey Date: Mon, 22 Mar 2021 18:55:32 +0000 Subject: [PATCH] Revert "Have a new method in NetworkAgentConfig.Builder to set allowBypass" This reverts commit d40b253b3d058b280570fb2942332238292571fe. Reason for revert: Broken build b/183416288 Change-Id: Id9ec9fb98b8f88eeb7db1d1442d76456aaf350d1 --- framework/api/module-lib-current.txt | 2 -- .../src/android/net/NetworkAgentConfig.java | 23 ------------------- 2 files changed, 25 deletions(-) diff --git a/framework/api/module-lib-current.txt b/framework/api/module-lib-current.txt index 663a4ff9db..9ca6d8fedc 100644 --- a/framework/api/module-lib-current.txt +++ b/framework/api/module-lib-current.txt @@ -36,11 +36,9 @@ package android.net { public final class NetworkAgentConfig implements android.os.Parcelable { method @Nullable public String getSubscriberId(); - method public boolean isBypassableVpn(); } public static final class NetworkAgentConfig.Builder { - method @NonNull public android.net.NetworkAgentConfig.Builder setBypassableVpn(boolean); method @NonNull public android.net.NetworkAgentConfig.Builder setSubscriberId(@Nullable String); } diff --git a/framework/src/android/net/NetworkAgentConfig.java b/framework/src/android/net/NetworkAgentConfig.java index 0bd2371bfc..5e50a6404a 100644 --- a/framework/src/android/net/NetworkAgentConfig.java +++ b/framework/src/android/net/NetworkAgentConfig.java @@ -63,16 +63,6 @@ public final class NetworkAgentConfig implements Parcelable { return explicitlySelected; } - /** - * @return whether this VPN connection can be bypassed by the apps. - * - * @hide - */ - @SystemApi(client = MODULE_LIBRARIES) - public boolean isBypassableVpn() { - return allowBypass; - } - /** * Set if the user desires to use this network even if it is unvalidated. This field has meaning * only if {@link explicitlySelected} is true. If it is, this field must also be set to the @@ -356,19 +346,6 @@ public final class NetworkAgentConfig implements Parcelable { return this; } - /** - * Sets whether the apps can bypass the VPN connection. - * - * @return this builder, to facilitate chaining. - * @hide - */ - @NonNull - @SystemApi(client = MODULE_LIBRARIES) - public Builder setBypassableVpn(boolean allowBypass) { - mConfig.allowBypass = allowBypass; - return this; - } - /** * Returns the constructed {@link NetworkAgentConfig} object. */