diff options
-rw-r--r-- | api/current.txt | 2 | ||||
-rw-r--r-- | api/system-current.txt | 2 | ||||
-rw-r--r-- | telecomm/java/android/telecom/TelecomManager.java | 13 | ||||
-rw-r--r-- | telecomm/java/com/android/internal/telecom/ITelecomService.aidl | 4 |
4 files changed, 11 insertions, 10 deletions
diff --git a/api/current.txt b/api/current.txt index b55a420..2bb55bc 100644 --- a/api/current.txt +++ b/api/current.txt @@ -28847,9 +28847,9 @@ package android.telecom { method public java.lang.String getLine1Number(android.telecom.PhoneAccountHandle); method public android.telecom.PhoneAccount getPhoneAccount(android.telecom.PhoneAccountHandle); method public android.telecom.PhoneAccountHandle getSimCallManager(); + method public java.lang.String getVoiceMailNumber(android.telecom.PhoneAccountHandle); method public boolean handleMmi(java.lang.String); method public boolean handleMmi(java.lang.String, android.telecom.PhoneAccountHandle); - method public boolean hasVoiceMailNumber(android.telecom.PhoneAccountHandle); method public boolean isInCall(); method public boolean isVoiceMailNumber(android.telecom.PhoneAccountHandle, java.lang.String); method public void registerPhoneAccount(android.telecom.PhoneAccount); diff --git a/api/system-current.txt b/api/system-current.txt index 805377f..3233869 100644 --- a/api/system-current.txt +++ b/api/system-current.txt @@ -30679,9 +30679,9 @@ package android.telecom { method public java.util.List<android.telecom.PhoneAccountHandle> getPhoneAccountsSupportingScheme(java.lang.String); method public java.util.List<android.telecom.PhoneAccountHandle> getRegisteredConnectionManagers(); method public android.telecom.PhoneAccountHandle getSimCallManager(); + method public java.lang.String getVoiceMailNumber(android.telecom.PhoneAccountHandle); method public boolean handleMmi(java.lang.String); method public boolean handleMmi(java.lang.String, android.telecom.PhoneAccountHandle); - method public boolean hasVoiceMailNumber(android.telecom.PhoneAccountHandle); method public boolean isInCall(); method public boolean isRinging(); method public boolean isTtySupported(); diff --git a/telecomm/java/android/telecom/TelecomManager.java b/telecomm/java/android/telecom/TelecomManager.java index c73f6c2..2ea84be 100644 --- a/telecomm/java/android/telecom/TelecomManager.java +++ b/telecomm/java/android/telecom/TelecomManager.java @@ -707,20 +707,21 @@ public class TelecomManager { } /** - * Return whether a given phone account has a voicemail number configured. + * Return the voicemail number for a given phone account. * - * @param accountHandle The handle for the account to check for a voicemail number. - * @return {@code true} If the given phone account has a voicemail number. + * @param accountHandle The handle for the phone account. + * @return The voicemail number for the phone account, and {@code null} if one has not been + * configured. */ - public boolean hasVoiceMailNumber(PhoneAccountHandle accountHandle) { + public String getVoiceMailNumber(PhoneAccountHandle accountHandle) { try { if (isServiceConnected()) { - return getTelecomService().hasVoiceMailNumber(accountHandle); + return getTelecomService().getVoiceMailNumber(accountHandle); } } catch (RemoteException e) { Log.e(TAG, "RemoteException calling ITelecomService#hasVoiceMailNumber.", e); } - return false; + return null; } /** diff --git a/telecomm/java/com/android/internal/telecom/ITelecomService.aidl b/telecomm/java/com/android/internal/telecom/ITelecomService.aidl index d2030f2..35db97f 100644 --- a/telecomm/java/com/android/internal/telecom/ITelecomService.aidl +++ b/telecomm/java/com/android/internal/telecom/ITelecomService.aidl @@ -121,9 +121,9 @@ interface ITelecomService { boolean isVoiceMailNumber(in PhoneAccountHandle accountHandle, String number); /** - * @see TelecomServiceImpl#hasVoiceMailNumber + * @see TelecomServiceImpl#getVoiceMailNumber */ - boolean hasVoiceMailNumber(in PhoneAccountHandle accountHandle); + String getVoiceMailNumber(in PhoneAccountHandle accountHandle); /** * @see TelecomServiceImpl#getLine1Number |