/packages/apps/Contacts/src/com/android/contacts/compat/ |
D | TelephonyManagerCompat.java | 42 public static boolean isVoiceCapable(@Nullable TelephonyManager telephonyManager) { in isVoiceCapable() argument 43 if (telephonyManager == null) { in isVoiceCapable() 49 return telephonyManager.isVoiceCapable(); in isVoiceCapable() 51 final int phoneType = telephonyManager.getPhoneType(); in isVoiceCapable() 65 public static int getPhoneCount(@Nullable TelephonyManager telephonyManager) { in getPhoneCount() argument 66 if (telephonyManager == null) { in getPhoneCount() 71 return telephonyManager.getPhoneCount(); in getPhoneCount() 86 public static String getDeviceId(@Nullable TelephonyManager telephonyManager, int slotId) { in getDeviceId() argument 87 if (telephonyManager == null) { in getDeviceId() 93 return telephonyManager.getDeviceId(slotId); in getDeviceId() [all …]
|
D | TelephonyManagerSdkCompat.java | 27 public static Uri getVoicemailRingtoneUri(TelephonyManager telephonyManager, in getVoicemailRingtoneUri() argument 30 ? telephonyManager.getVoicemailRingtoneUri(accountHandle) : null; in getVoicemailRingtoneUri() 33 public static boolean isVoicemailVibrationEnabled(TelephonyManager telephonyManager, in isVoicemailVibrationEnabled() argument 36 ? telephonyManager.isVoicemailVibrationEnabled(accountHandle) : false; in isVoicemailVibrationEnabled()
|
/packages/apps/Dialer/java/com/android/dialer/compat/telephony/ |
D | TelephonyManagerCompat.java | 96 public static int getPhoneCount(@Nullable TelephonyManager telephonyManager) { in getPhoneCount() argument 97 if (telephonyManager == null) { in getPhoneCount() 100 return telephonyManager.getPhoneCount(); in getPhoneCount() 109 public static boolean isTtyModeSupported(@Nullable TelephonyManager telephonyManager) { in isTtyModeSupported() argument 110 return telephonyManager != null && telephonyManager.isTtyModeSupported(); in isTtyModeSupported() 121 @Nullable TelephonyManager telephonyManager) { in isHearingAidCompatibilitySupported() 122 return telephonyManager != null && telephonyManager.isHearingAidCompatibilitySupported(); in isHearingAidCompatibilitySupported() 136 TelephonyManager telephonyManager, PhoneAccountHandle accountHandle) { in getVoicemailRingtoneUri() argument 137 return telephonyManager.getVoicemailRingtoneUri(accountHandle); in getVoicemailRingtoneUri() 149 TelephonyManager telephonyManager, PhoneAccountHandle accountHandle) { in isVoicemailVibrationEnabled() argument [all …]
|
/packages/apps/Dialer/java/com/android/dialer/assisteddialing/ |
D | LocationDetector.java | 34 private final TelephonyManager telephonyManager; field in LocationDetector 38 @NonNull TelephonyManager telephonyManager, @Nullable String userProvidedHomeCountry) { in LocationDetector() 39 if (telephonyManager == null) { in LocationDetector() 43 this.telephonyManager = telephonyManager; in LocationDetector() 62 String simCountryIso = telephonyManager.getSimCountryIso(); in getUpperCaseUserHomeCountry() 65 return Optional.of(telephonyManager.getSimCountryIso().toUpperCase(Locale.US)); in getUpperCaseUserHomeCountry() 74 String networkCountryIso = telephonyManager.getNetworkCountryIso(); in getUpperCaseUserRoamingCountry() 76 return Optional.of(telephonyManager.getNetworkCountryIso().toUpperCase(Locale.US)); in getUpperCaseUserRoamingCountry()
|
/packages/services/Telephony/src/com/android/phone/settings/ |
D | SuppServicesUiUtil.java | 92 TelephonyManager telephonyManager = in makeMessage() local 94 boolean isRoaming = telephonyManager.isNetworkRoaming(phone.getSubId()); in makeMessage() 95 boolean isMultiSim = (telephonyManager.getSimCount() > 1); in makeMessage() 149 TelephonyManager telephonyManager = in isMobileDataOff() local 151 return !telephonyManager.getDataEnabled(phone.getSubId()); in isMobileDataOff() 155 TelephonyManager telephonyManager = in isDataRoamingOffUnderRoaming() local 157 return telephonyManager.isNetworkRoaming(phone.getSubId()) in isDataRoamingOffUnderRoaming() 176 TelephonyManager telephonyManager = new TelephonyManager(context, phone.getSubId()); in handleCallerIdUssdResponse() local 177 int carrierId = telephonyManager.getSimCarrierId(); in handleCallerIdUssdResponse() 206 final TelephonyManager telephonyManager, in handleCallerIdUssdResponse() [all …]
|
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/network/ |
D | NetworkUtilsTest.java | 65 TelephonyManager telephonyManager = mock(TelephonyManager.class); in hasSim_simAbsent_returnsFalse() local 66 when(telephonyManager.getSimState()).thenReturn(TelephonyManager.SIM_STATE_ABSENT); in hasSim_simAbsent_returnsFalse() 68 assertThat(NetworkUtils.hasSim(telephonyManager)).isFalse(); in hasSim_simAbsent_returnsFalse() 73 TelephonyManager telephonyManager = mock(TelephonyManager.class); in hasSim_simUnknown_returnsFalse() local 74 when(telephonyManager.getSimState()).thenReturn(TelephonyManager.SIM_STATE_UNKNOWN); in hasSim_simUnknown_returnsFalse() 76 assertThat(NetworkUtils.hasSim(telephonyManager)).isFalse(); in hasSim_simUnknown_returnsFalse() 81 TelephonyManager telephonyManager = mock(TelephonyManager.class); in hasSim_otherStatus_returnsTrue() local 82 when(telephonyManager.getSimState()).thenReturn(TelephonyManager.SIM_STATE_LOADED); in hasSim_otherStatus_returnsTrue() 84 assertThat(NetworkUtils.hasSim(telephonyManager)).isTrue(); in hasSim_otherStatus_returnsTrue()
|
D | SubscriptionUtilsTest.java | 44 TelephonyManager telephonyManager = mock(TelephonyManager.class); in getAvailableSubscriptions_hasSubscriptionsFromSubscriptionManager_valueReturned() local 50 when(telephonyManager.getUiccSlotsInfo()).thenReturn(new UiccSlotInfo[0]); in getAvailableSubscriptions_hasSubscriptionsFromSubscriptionManager_valueReturned() 53 subscriptionManager, telephonyManager); in getAvailableSubscriptions_hasSubscriptionsFromSubscriptionManager_valueReturned() 61 TelephonyManager telephonyManager = mock(TelephonyManager.class); in getAvailableSubscriptions_hasSimSlotNotInSubscriptionManager_valueReturned() local 71 when(telephonyManager.getUiccSlotsInfo()).thenReturn(new UiccSlotInfo[]{slotInfo}); in getAvailableSubscriptions_hasSimSlotNotInSubscriptionManager_valueReturned() 74 subscriptionManager, telephonyManager); in getAvailableSubscriptions_hasSimSlotNotInSubscriptionManager_valueReturned() 82 TelephonyManager telephonyManager = mock(TelephonyManager.class); in getAvailableSubscriptions_hasInactiveInsertedPSim_valueRemoved() local 88 when(telephonyManager.getUiccSlotsInfo()).thenReturn(new UiccSlotInfo[0]); in getAvailableSubscriptions_hasInactiveInsertedPSim_valueRemoved() 91 subscriptionManager, telephonyManager); in getAvailableSubscriptions_hasInactiveInsertedPSim_valueRemoved()
|
/packages/services/Telephony/src/com/android/phone/vvm/ |
D | VvmSimStateTracker.java | 82 TelephonyManager telephonyManager = getTelephonyManager(mContext, mPhoneAccountHandle); in listen() local 83 if(telephonyManager == null){ in listen() 87 telephonyManager.listen(this, PhoneStateListener.LISTEN_SERVICE_STATE); in listen() 157 TelephonyManager telephonyManager = getTelephonyManager(context, phoneAccountHandle); in onBootCompleted() local 158 if (telephonyManager == null) { in onBootCompleted() 161 if (telephonyManager.getServiceState().getState() == ServiceState.STATE_IN_SERVICE) { in onBootCompleted() 217 TelephonyManager telephonyManager = getTelephonyManager(context, phoneAccountHandle); in onCarrierConfigChanged() local 218 if(telephonyManager == null){ in onCarrierConfigChanged() 229 if (telephonyManager.getServiceState().getState() in onCarrierConfigChanged()
|
/packages/services/Telephony/src/com/android/phone/ |
D | ShortcutViewUtils.java | 211 TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class); in pickPreferredPhone() local 212 if (telephonyManager.getPhoneCount() <= 0) { in pickPreferredPhone() 218 getPromotedEmergencyNumberLists(telephonyManager); in pickPreferredPhone() 228 PhoneInfo phone = loadPhoneInfo(defaultHandle, telephonyManager, telecomManager, in pickPreferredPhone() 243 PhoneInfo phone = loadPhoneInfo(handle, telephonyManager, telecomManager, in pickPreferredPhone() 276 @NonNull TelephonyManager telephonyManager, @NonNull TelecomManager telecomManager, in loadPhoneInfo() argument 287 subId = telephonyManager.getSubIdForPhoneAccount(phoneAccount); in loadPhoneInfo() 290 TelephonyManager subTelephonyManager = telephonyManager.createForSubscriptionId(subId); in loadPhoneInfo() 304 @NonNull TelephonyManager telephonyManager) { in getPromotedEmergencyNumberLists() 306 telephonyManager.getEmergencyNumberList(); in getPromotedEmergencyNumberLists()
|
D | CallForwardEditPreference.java | 93 TelephonyManager telephonyManager = new TelephonyManager(getContext(), in init() local 96 telephonyManager.getSimCarrierId()); in init() 262 final TelephonyManager telephonyManager = in getCurrentCountryIso() local 264 if (telephonyManager == null) { in getCurrentCountryIso() 267 return telephonyManager.getNetworkCountryIso().toUpperCase(); in getCurrentCountryIso() 283 public void onReceiveUssdResponse(final TelephonyManager telephonyManager, 310 public void onReceiveUssdResponseFailed(final TelephonyManager telephonyManager, 463 TelephonyManager telephonyManager = in sendUssdCommand() local 465 telephonyManager.sendUssdRequest(newUssdCommand, inputCallback, mHandler); in sendUssdCommand()
|
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/network/telephony/ |
D | MobileNetworkUtils.java | 222 final TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class) in setMobileDataEnabled() local 226 telephonyManager.setDataEnabled(enabled); in setMobileDataEnabled() 250 final TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class) in isCdmaOptions() local 256 if (telephonyManager.getPhoneType() == PhoneConstants.PHONE_TYPE_CDMA) { in isCdmaOptions() 276 && !isTdscdmaSupported(context, telephonyManager)) { in isCdmaOptions() 312 final TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class) in isGsmBasicOptions() local 317 if (telephonyManager.getPhoneType() == PhoneConstants.PHONE_TYPE_GSM) { in isGsmBasicOptions() 345 final TelephonyManager telephonyManager = TelephonyManager.from(context) in shouldDisplayNetworkSelectOptions() local 354 && !telephonyManager.isManualNetworkSelectionAllowed())) { in shouldDisplayNetworkSelectOptions() 384 private static boolean isTdscdmaSupported(Context context, TelephonyManager telephonyManager) { in isTdscdmaSupported() argument [all …]
|
/packages/services/Mms/src/com/android/mms/service/ |
D | PhoneUtils.java | 42 public static String getNationalNumber(TelephonyManager telephonyManager, int subId, in getNationalNumber() argument 44 final String country = getSimOrDefaultLocaleCountry(telephonyManager, subId); in getNationalNumber() 74 private static String getSimOrDefaultLocaleCountry(TelephonyManager telephonyManager, in getSimOrDefaultLocaleCountry() argument 76 String country = getSimCountry(telephonyManager, subId); in getSimOrDefaultLocaleCountry() 85 private static String getSimCountry(TelephonyManager telephonyManager, int subId) { in getSimCountry() argument 86 final String country = telephonyManager.getSimCountryIso(subId); in getSimCountry()
|
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/datausage/ |
D | DataUsageUtils.java | 74 final TelephonyManager telephonyManager = TelephonyManager.from(context);; in hasEthernet() local 80 ConnectivityManager.TYPE_ETHERNET, telephonyManager.getSubscriberId(), in hasEthernet() 150 TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class); in hasSim() local 151 final int simState = telephonyManager.getSimState(); in hasSim() 183 TelephonyManager telephonyManager = TelephonyManager.from(context); in getDefaultTemplate() local 185 telephonyManager.getSubscriberId(defaultSubId)); in getDefaultTemplate() 187 telephonyManager.getMergedSubscriberIds()); in getDefaultTemplate()
|
/packages/apps/Dialer/java/com/android/dialer/precall/impl/ |
D | AssistedDialAction.java | 88 TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class); in getAssistedDialingTelephonyManager() local 92 return telephonyManager; in getAssistedDialingTelephonyManager() 96 return telephonyManager; in getAssistedDialingTelephonyManager() 104 return telephonyManager; in getAssistedDialingTelephonyManager() 107 telephonyManager.createForSubscriptionId(subscriptionInfo.get().getSubscriptionId()); in getAssistedDialingTelephonyManager() 112 return telephonyManager; in getAssistedDialingTelephonyManager()
|
/packages/apps/Dialer/java/com/android/dialer/location/ |
D | CountryDetector.java | 78 private final TelephonyManager telephonyManager; field in CountryDetector 86 TelephonyManager telephonyManager, in CountryDetector() argument 90 this.telephonyManager = telephonyManager; in CountryDetector() 161 return telephonyManager.getNetworkCountryIso(); in getNetworkBasedCountryIso() 178 return telephonyManager.getSimCountryIso(); in getSimBasedCountryIso() 193 return telephonyManager.getPhoneType() == TelephonyManager.PHONE_TYPE_GSM; in isNetworkCountryCodeAvailable()
|
/packages/apps/Settings/src/com/android/settings/network/telephony/ |
D | MobileNetworkUtils.java | 239 final TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class) in setMobileDataEnabled() local 243 telephonyManager.setDataEnabled(enabled); in setMobileDataEnabled() 267 final TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class) in isCdmaOptions() local 273 if (telephonyManager.getPhoneType() == PhoneConstants.PHONE_TYPE_CDMA) { in isCdmaOptions() 327 final TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class) in isGsmBasicOptions() local 332 if (telephonyManager.getPhoneType() == PhoneConstants.PHONE_TYPE_GSM) { in isGsmBasicOptions() 360 final TelephonyManager telephonyManager = TelephonyManager.from(context) in shouldDisplayNetworkSelectOptions() local 371 && !telephonyManager.isManualNetworkSelectionAllowed())) { in shouldDisplayNetworkSelectOptions() 409 private static boolean isTdscdmaSupported(Context context, TelephonyManager telephonyManager) { in isTdscdmaSupported() argument 421 String operatorNumeric = telephonyManager.getServiceState().getOperatorNumeric(); in isTdscdmaSupported()
|
/packages/apps/Dialer/java/com/android/dialer/dialpadview/ |
D | SpecialCharSequenceMgr.java | 174 TelephonyManager telephonyManager = in handleAdnEntry() local 176 if (telephonyManager == null in handleAdnEntry() 177 || telephonyManager.getPhoneType() != TelephonyManager.PHONE_TYPE_GSM) { in handleAdnEntry() 315 TelephonyManager telephonyManager = in handleDeviceIdDisplay() local 318 if (telephonyManager != null && input.equals(MMI_IMEI_DISPLAY)) { in handleDeviceIdDisplay() 320 (telephonyManager.getPhoneType() == TelephonyManager.PHONE_TYPE_GSM) in handleDeviceIdDisplay() 327 if (TelephonyManagerCompat.getPhoneCount(telephonyManager) > 1) { in handleDeviceIdDisplay() 328 for (int slot = 0; slot < telephonyManager.getPhoneCount(); slot++) { in handleDeviceIdDisplay() 329 String deviceId = telephonyManager.getDeviceId(slot); in handleDeviceIdDisplay() 342 telephonyManager.getDeviceId(), in handleDeviceIdDisplay()
|
/packages/apps/Contacts/src/com/android/contacts/util/ |
D | TelephonyManagerUtils.java | 37 final TelephonyManager telephonyManager = in getVoiceMailAlphaTag() local 39 final String voiceMailLabel = telephonyManager.getVoiceMailAlphaTag(); in getVoiceMailAlphaTag() 51 final TelephonyManager telephonyManager = in getCurrentCountryIso() local 53 String countryIso = telephonyManager.getNetworkCountryIso().toUpperCase(); in getCurrentCountryIso()
|
/packages/apps/Dialer/java/com/android/dialer/app/voicemail/ |
D | VoicemailErrorManager.java | 112 TelephonyManager telephonyManager = in addServiceStateListener() local 116 if (telephonyManager == null) { in addServiceStateListener() 128 telephonyManager.listen(serviceStateListener, PhoneStateListener.LISTEN_SERVICE_STATE); in addServiceStateListener() 161 TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class); in onDestroy() local 163 telephonyManager.listen(listener, PhoneStateListener.LISTEN_NONE); in onDestroy()
|
/packages/apps/Dialer/java/com/android/voicemail/impl/ |
D | CarrierIdentifier.java | 63 TelephonyManager telephonyManager = in forHandle() local 67 if (telephonyManager == null) { in forHandle() 70 String gid1 = telephonyManager.getGroupIdLevel1(); in forHandle() 76 builder().setMccMnc(telephonyManager.getSimOperator()).setGid1(gid1).build()); in forHandle()
|
/packages/apps/Car/Settings/src/com/android/car/settings/network/ |
D | NetworkUtils.java | 48 public static boolean hasSim(TelephonyManager telephonyManager) { in hasSim() argument 49 int simState = telephonyManager.getSimState(); in hasSim() 63 TelephonyManager telephonyManager = context.getSystemService(TelephonyManager.class) in setMobileDataEnabled() local 67 telephonyManager.setDataEnabled(enabled); in setMobileDataEnabled()
|
/packages/apps/Contacts/src/com/android/contacts/location/ |
D | CountryDetector.java | 52 private CountryDetector(Context context, TelephonyManager telephonyManager, in CountryDetector() argument 54 mTelephonyManager = telephonyManager; in CountryDetector() 62 public CountryDetector getInstanceForTest(Context context, TelephonyManager telephonyManager, in getInstanceForTest() argument 64 return new CountryDetector(context, telephonyManager, localeProvider); in getInstanceForTest()
|
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/connectivity/ |
D | ConnectivityListener.java | 142 final TelephonyManager telephonyManager = mContext in onStart() local 144 if (telephonyManager != null) { in onStart() 145 telephonyManager.listen(mPhoneStateListener, in onStart() 172 final TelephonyManager telephonyManager = mContext in onStop() local 174 if (telephonyManager != null) { in onStop() 175 telephonyManager.listen(mPhoneStateListener, PhoneStateListener.LISTEN_NONE); in onStop()
|
/packages/services/Telecomm/testapps/src/com/android/server/telecom/testapps/ |
D | TestUssdActivity.java | 24 public void onReceiveUssdResponse(final TelephonyManager telephonyManager, 31 public void onReceiveUssdResponseFailed(final TelephonyManager telephonyManager, 64 final TelephonyManager telephonyManager = in placeUssdRequest() local 69 telephonyManager.sendUssdRequest(mUssdNumber, mReceiveUssdResponseCallback, h); in placeUssdRequest()
|
/packages/services/Car/tests/CarDeveloperOptions/src/com/android/car/developeroptions/sim/ |
D | SimDialogActivity.java | 121 final TelephonyManager telephonyManager = TelephonyManager.from(context) in setDefaultDataSubId() local 124 telephonyManager.setDataEnabled(true); in setDefaultDataSubId() 140 final TelephonyManager telephonyManager = TelephonyManager.from(this); in subscriptionIdToPhoneAccountHandle() local 147 if (subId == telephonyManager.getSubIdForPhoneAccount(phoneAccount)) { in subscriptionIdToPhoneAccountHandle() 209 final TelephonyManager telephonyManager = TelephonyManager.from(context); in createDialog() local 219 int subId = telephonyManager.getSubIdForPhoneAccount(phoneAccount); in createDialog()
|