summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> 2020-02-27 19:34:58 +0000
committer Tyler Gunn <tgunn@google.com> 2020-04-02 18:24:50 +0000
commit031f56f2bc58a57b1004134057c95499d5624155 (patch)
treeed94f94dadc03b0fd61af7c258f6f56487de5c77
parentb164ea9d7ab9d1e9771069310f919e408c43ccee (diff)
Update EmergencyNumber API docs to indicate they can throw.
Adding @throws tags for EmergencyNumber APIs so that callers are aware that they can throw. Test: Build; docs only change. Bug: 134100020 Fixes: 152231444 Merged-In: Ic6bcd32ab93a97a8d075e720acb5fc17612a3984 Change-Id: Ic6bcd32ab93a97a8d075e720acb5fc17612a3984 (cherry picked from commit 5fe27428f06a7bfd439db96d0418323687010986)
-rw-r--r--telephony/java/android/telephony/TelephonyManager.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java
index 4e5be5c453b7..09231d86a92b 100644
--- a/telephony/java/android/telephony/TelephonyManager.java
+++ b/telephony/java/android/telephony/TelephonyManager.java
@@ -11776,6 +11776,7 @@ public class TelephonyManager {
* subscription, the key is {@link SubscriptionManager#getDefaultSubscriptionId}) and the value
* as the list of {@link EmergencyNumber}; empty Map if this information is not available;
* or throw a SecurityException if the caller does not have the permission.
+ * @throws IllegalStateException if the Telephony process is not currently available.
*/
@RequiresPermission(android.Manifest.permission.READ_PHONE_STATE)
@NonNull
@@ -11823,6 +11824,7 @@ public class TelephonyManager {
* @param number - the number to look up
* @return {@code true} if the given number is an emergency number based on current locale,
* SIM card(s), Android database, modem, network or defaults; {@code false} otherwise.
+ * @throws IllegalStateException if the Telephony process is not currently available.
*/
public boolean isEmergencyNumber(@NonNull String number) {
try {
@@ -11858,7 +11860,7 @@ public class TelephonyManager {
* the same digits of any current emergency number based on current locale, sim, modem and
* network; {@code false} if it is not; or throw an SecurityException if the caller does not
* have the required permission/privileges
- *
+ * @throws IllegalStateException if the Telephony process is not currently available.
* @hide
*/
@SystemApi