summaryrefslogtreecommitdiff
path: root/telephony
diff options
context:
space:
mode:
authorBrad Ebinger <breadley@google.com>2021-02-26 20:45:18 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2021-02-26 20:45:18 +0000
commit44d6bdc3326dce80294ede5eda3f4cb305c55ad0 (patch)
treeafc4349845d9cfabdddfcde8e27ba008369a0c3f /telephony
parentd600f5067afec168699aad232a5d246bc9fd95bc (diff)
parent89165368220798ccf5bc6518f1561d2c902dc6f3 (diff)
Merge "[RCS UCE] Define a new ACCESS_RCS_USER_CAPABILITY_EXCHANGE permission for associated RCS UCE APIs"
Diffstat (limited to 'telephony')
-rw-r--r--telephony/java/android/telephony/ims/RcsUceAdapter.java10
1 files changed, 6 insertions, 4 deletions
diff --git a/telephony/java/android/telephony/ims/RcsUceAdapter.java b/telephony/java/android/telephony/ims/RcsUceAdapter.java
index 070fd799d6cc..ce8bd7d8c28e 100644
--- a/telephony/java/android/telephony/ims/RcsUceAdapter.java
+++ b/telephony/java/android/telephony/ims/RcsUceAdapter.java
@@ -467,7 +467,7 @@ public class RcsUceAdapter {
* poll on the network unless there are contacts being queried with stale information.
* <p>
* Be sure to check the availability of this feature using
- * {@link ImsRcsManager#isAvailable(int)} and ensuring
+ * {@link ImsRcsManager#isAvailable(int, int)} and ensuring
* {@link RcsFeature.RcsImsCapabilities#CAPABILITY_TYPE_OPTIONS_UCE} or
* {@link RcsFeature.RcsImsCapabilities#CAPABILITY_TYPE_PRESENCE_UCE} is enabled or else
* this operation will fail with {@link #ERROR_NOT_AVAILABLE} or {@link #ERROR_NOT_ENABLED}.
@@ -484,7 +484,8 @@ public class RcsUceAdapter {
* @hide
*/
@SystemApi
- @RequiresPermission(Manifest.permission.READ_PRIVILEGED_PHONE_STATE)
+ @RequiresPermission(allOf = {Manifest.permission.ACCESS_RCS_USER_CAPABILITY_EXCHANGE,
+ Manifest.permission.READ_CONTACTS})
public void requestCapabilities(@NonNull List<Uri> contactNumbers,
@NonNull @CallbackExecutor Executor executor,
@NonNull CapabilitiesCallback c) throws ImsException {
@@ -557,7 +558,7 @@ public class RcsUceAdapter {
*
* <p>
* Be sure to check the availability of this feature using
- * {@link ImsRcsManager#isAvailable(int)} and ensuring
+ * {@link ImsRcsManager#isAvailable(int, int)} and ensuring
* {@link RcsFeature.RcsImsCapabilities#CAPABILITY_TYPE_OPTIONS_UCE} or
* {@link RcsFeature.RcsImsCapabilities#CAPABILITY_TYPE_PRESENCE_UCE} is
* enabled or else this operation will fail with
@@ -571,7 +572,8 @@ public class RcsUceAdapter {
* @hide
*/
@SystemApi
- @RequiresPermission(Manifest.permission.MODIFY_PHONE_STATE)
+ @RequiresPermission(allOf = {Manifest.permission.ACCESS_RCS_USER_CAPABILITY_EXCHANGE,
+ Manifest.permission.READ_CONTACTS})
public void requestAvailability(@NonNull Uri contactNumber,
@NonNull @CallbackExecutor Executor executor,
@NonNull CapabilitiesCallback c) throws ImsException {