API Review: Clarify deprecated docs and rethrow from system server

1) Clarify why there are new APIs being added as @deprecated
   (backwards compatibility), and
2) onLineIdentificationSupplementaryServiceResponse should throw
an exception instead of silently failing.

Test: atest CtsTelephonyTestCases FrameworksTelephonyTests
Fixes: 149997057
Fixes: 143987946
Change-Id: I5c2bacad43917a6ecad49dcf9d3213b3472534cc
This commit is contained in:
Brad Ebinger
2020-03-06 10:36:06 -08:00
parent fadcd80471
commit 6d8722cb87

View File

@@ -49,7 +49,8 @@ public class ImsUtListener {
* {@link ImsSsInfo#CLIR_STATUS_TEMPORARILY_RESTRICTED}, and
* {@link ImsSsInfo#CLIR_STATUS_TEMPORARILY_ALLOWED}.
* @deprecated Use {@link #onLineIdentificationSupplementaryServiceResponse(int, ImsSsInfo)}
* instead.
* instead, this key has been added for backwards compatibility with older proprietary
* implementations only and is being phased out.
*/
@Deprecated
public static final String BUNDLE_KEY_CLIR = "queryClir";
@@ -60,7 +61,8 @@ public class ImsUtListener {
* response. The value will be an instance of {@link ImsSsInfo}, which contains the response to
* the query.
* @deprecated Use {@link #onLineIdentificationSupplementaryServiceResponse(int, ImsSsInfo)}
* instead.
* instead, this key has been added for backwards compatibility with older proprietary
* implementations only and is being phased out.
*/
@Deprecated
public static final String BUNDLE_KEY_SSINFO = "imsSsInfo";
@@ -123,7 +125,7 @@ public class ImsUtListener {
try {
mServiceInterface.lineIdentificationSupplementaryServiceResponse(id, configuration);
} catch (RemoteException e) {
Log.w(LOG_TAG, "onLineIdentificationSupplementaryServicesResponse: remote exception");
e.rethrowFromSystemServer();
}
}