diff options
author | James Lin <jamescflin@google.com> | 2021-02-26 09:49:57 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2021-02-26 09:49:57 +0000 |
commit | a2d03f9eecc5336959ec2ea55a682b597d13d745 (patch) | |
tree | a86262a9b6cf019b496a7d928c8ede3b20f83040 | |
parent | c8057ecd1c01147ae795c5121654b356e7b509e2 (diff) | |
parent | 12b5644a43063c28b45b0100b3629975047f3b05 (diff) |
Merge "Update the UCE OPTIONS API"
-rw-r--r-- | core/api/system-current.txt | 2 | ||||
-rw-r--r-- | telephony/java/android/telephony/ims/stub/CapabilityExchangeEventListener.java | 23 |
2 files changed, 3 insertions, 22 deletions
diff --git a/core/api/system-current.txt b/core/api/system-current.txt index b15544775a8b..8d43299d3382 100644 --- a/core/api/system-current.txt +++ b/core/api/system-current.txt @@ -12295,7 +12295,7 @@ package android.telephony.ims.stub { } public static interface CapabilityExchangeEventListener.OptionsRequestCallback { - method public default void onRespondToCapabilityRequest(@NonNull android.telephony.ims.RcsContactUceCapability, boolean); + method public void onRespondToCapabilityRequest(@NonNull android.telephony.ims.RcsContactUceCapability, boolean); method public void onRespondToCapabilityRequestWithError(@IntRange(from=100, to=699) int, @NonNull String); } diff --git a/telephony/java/android/telephony/ims/stub/CapabilityExchangeEventListener.java b/telephony/java/android/telephony/ims/stub/CapabilityExchangeEventListener.java index 4967e5da7c9a..62955487897f 100644 --- a/telephony/java/android/telephony/ims/stub/CapabilityExchangeEventListener.java +++ b/telephony/java/android/telephony/ims/stub/CapabilityExchangeEventListener.java @@ -25,7 +25,6 @@ import android.telephony.ims.RcsContactUceCapability; import android.telephony.ims.RcsUceAdapter; import android.telephony.ims.feature.ImsFeature; import android.telephony.ims.feature.RcsFeature; -import android.util.Log; import java.util.List; @@ -44,30 +43,12 @@ public interface CapabilityExchangeEventListener { * Respond to a remote capability request from the contact specified with the * capabilities of this device. * @param ownCapabilities The capabilities of this device. - * @hide - */ - default void onRespondToCapabilityRequest( - @NonNull RcsContactUceCapability ownCapabilities) {} - - /** - * Respond to a remote capability request from the contact specified with the - * capabilities of this device. - * @param ownCapabilities The capabilities of this device. * @param isBlocked Whether or not the user has blocked the number requesting the * capabilities of this device. If true, the device should respond to the OPTIONS * request with a 200 OK response and no capabilities. */ - default void onRespondToCapabilityRequest(@NonNull RcsContactUceCapability ownCapabilities, - boolean isBlocked) { - Log.w("CapabilityExchangeEventListener", "implement " - + "onRespondToCapabilityRequest(RcsContactUceCapability, boolean) instead!"); - // Fall back to old implementation - if (isBlocked) { - onRespondToCapabilityRequestWithError(200, "OK"); - } else { - onRespondToCapabilityRequest(ownCapabilities); - } - } + void onRespondToCapabilityRequest(@NonNull RcsContactUceCapability ownCapabilities, + boolean isBlocked); /** * Respond to a remote capability request from the contact specified with the |