From a61992b67adf0180a073da5820826c27fd8d5e88 Mon Sep 17 00:00:00 2001 From: Nathan Harold Date: Wed, 29 Jan 2020 16:17:22 -0800 Subject: [PATCH] Expose PreciseDataConnectionstate#getApnSetting() Expose an API that was accidentally left as package private. This is was missed when exposing other methods for the same class; however, other methods have been deprecated based on the presumption that this method is available in the public API. This method deprecated: PreciseDataConnectionState#getDataConnectionApnTypeBitMask() PreciseDataConnectionState#getDataConnectionApn() Bug: 148565164 Bug: 147600208 Test: make update-api && make offline-sdk-docs Change-Id: I0207c18d853d0b83db2622ff3abcda98565eac30 --- api/current.txt | 1 + .../java/android/telephony/PreciseDataConnectionState.java | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/api/current.txt b/api/current.txt index 39b52545f1d52..da27125f1ef4a 100644 --- a/api/current.txt +++ b/api/current.txt @@ -47291,6 +47291,7 @@ package android.telephony { public final class PreciseDataConnectionState implements android.os.Parcelable { method public int describeContents(); + method @Nullable public android.telephony.data.ApnSetting getApnSetting(); method public int getLastCauseCode(); method @Nullable public android.net.LinkProperties getLinkProperties(); method public int getNetworkType(); diff --git a/telephony/java/android/telephony/PreciseDataConnectionState.java b/telephony/java/android/telephony/PreciseDataConnectionState.java index 54c22ae282fb2..708adebb6db34 100644 --- a/telephony/java/android/telephony/PreciseDataConnectionState.java +++ b/telephony/java/android/telephony/PreciseDataConnectionState.java @@ -265,10 +265,10 @@ public final class PreciseDataConnectionState implements Parcelable { /** * Return the APN Settings for this data connection. * - * Returns the ApnSetting that was used to configure this data connection. + * @return the ApnSetting that was used to configure this data connection. */ // FIXME: This shouldn't be nullable; update once the ApnSetting is supplied correctly - @Nullable ApnSetting getApnSetting() { + public @Nullable ApnSetting getApnSetting() { return mApnSetting; }