From 84a217a6ef13761bd8129ebf7f564a6730f4e59d Mon Sep 17 00:00:00 2001 From: Remi NGUYEN VAN Date: Thu, 8 Apr 2021 15:56:28 +0900 Subject: [PATCH] Set ParseException constructors as public As there is no strong reason to keep the constructors module-lib, set them as public API. This is in response to API feedback. Fixes: 183446251 Test: m Change-Id: I01daa6f6f8095f7a4db94d1ca05f913166939df3 --- framework/api/current.txt | 2 ++ framework/api/module-lib-current.txt | 5 ----- framework/src/android/net/ParseException.java | 5 ----- 3 files changed, 2 insertions(+), 10 deletions(-) diff --git a/framework/api/current.txt b/framework/api/current.txt index ab290f9d70..7692e30c31 100644 --- a/framework/api/current.txt +++ b/framework/api/current.txt @@ -410,6 +410,8 @@ package android.net { } public class ParseException extends java.lang.RuntimeException { + ctor public ParseException(@NonNull String); + ctor public ParseException(@NonNull String, @NonNull Throwable); field public String response; } diff --git a/framework/api/module-lib-current.txt b/framework/api/module-lib-current.txt index 513b6308f3..5cf12b26dd 100644 --- a/framework/api/module-lib-current.txt +++ b/framework/api/module-lib-current.txt @@ -132,11 +132,6 @@ package android.net { method @NonNull public android.net.NetworkRequest.Builder setUids(@Nullable java.util.Set>); } - public class ParseException extends java.lang.RuntimeException { - ctor public ParseException(@NonNull String); - ctor public ParseException(@NonNull String, @NonNull Throwable); - } - public final class TcpRepairWindow { ctor public TcpRepairWindow(int, int, int, int, int, int); field public final int maxWindow; diff --git a/framework/src/android/net/ParseException.java b/framework/src/android/net/ParseException.java index ca6d012dfe..9d4727a84b 100644 --- a/framework/src/android/net/ParseException.java +++ b/framework/src/android/net/ParseException.java @@ -17,7 +17,6 @@ package android.net; import android.annotation.NonNull; -import android.annotation.SystemApi; /** * Thrown when parsing failed. @@ -26,15 +25,11 @@ import android.annotation.SystemApi; public class ParseException extends RuntimeException { public String response; - /** @hide */ - @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES) public ParseException(@NonNull String response) { super(response); this.response = response; } - /** @hide */ - @SystemApi(client = SystemApi.Client.MODULE_LIBRARIES) public ParseException(@NonNull String response, @NonNull Throwable cause) { super(response, cause); this.response = response;