CDMALTEPhone.java revision b93bb3538c55f173f94a4ee7510d9d1521d8f731
11260f1c6c909f2940989b72afe1b91fd83845eaaSukanya Rajkhowa/* 2ace9a749c5a2a5e07527f728b7331423d16c36cdSukanya Rajkhowa * Copyright (C) 2011 The Android Open Source Project 3c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * 4c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * Licensed under the Apache License, Version 2.0 (the "License"); 5c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * you may not use this file except in compliance with the License. 6c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * You may obtain a copy of the License at 7c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * 8c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * http://www.apache.org/licenses/LICENSE-2.0 9c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * 10c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * Unless required by applicable law or agreed to in writing, software 11c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * distributed under the License is distributed on an "AS IS" BASIS, 12c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * See the License for the specific language governing permissions and 14c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville * limitations under the License. 15c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville */ 16c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 17c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savillepackage com.android.internal.telephony.cdma; 18c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 19a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport android.app.ActivityManagerNative; 20c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport android.content.ContentValues; 21c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport android.content.Context; 22a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport android.content.Intent; 23c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport android.content.SharedPreferences; 24c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport android.database.SQLException; 25c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport android.net.Uri; 26c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport android.os.AsyncResult; 27a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport android.os.Handler; 28c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport android.os.Message; 29a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport android.os.UserHandle; 30c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport android.preference.PreferenceManager; 31a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport android.os.PowerManager; 32a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport android.os.SystemProperties; 33c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport android.provider.Telephony; 34a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport android.text.TextUtils; 35a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport android.telephony.SubscriptionManager; 36ded9c0af7fa49504c047275ed34c2d3b22bf0c3aWink Savilleimport android.telephony.Rlog; 37c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 38c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport com.android.internal.telephony.CommandsInterface; 39a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport android.telephony.TelephonyManager; 401260f1c6c909f2940989b72afe1b91fd83845eaaSukanya Rajkhowa 41a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport com.android.internal.telephony.dataconnection.DcTracker; 42a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport com.android.internal.telephony.MccTable; 43c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport com.android.internal.telephony.OperatorInfo; 44c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport com.android.internal.telephony.PhoneConstants; 45c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport com.android.internal.telephony.PhoneNotifier; 46c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport com.android.internal.telephony.PhoneProxy; 47a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport com.android.internal.telephony.PhoneFactory; 48a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport com.android.internal.telephony.PhoneSubInfo; 49c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport com.android.internal.telephony.SMSDispatcher; 500d4bcdf379842af4b6304809156971e926f374f0Jake Hambyimport com.android.internal.telephony.SmsBroadcastUndelivered; 51a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport com.android.internal.telephony.Subscription; 52c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport com.android.internal.telephony.gsm.GsmSMSDispatcher; 53c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport com.android.internal.telephony.gsm.SmsMessage; 54d720945f2be5ea5fe0faf67e67d9ea0e184eba67Alex Yakavenkaimport com.android.internal.telephony.uicc.IsimRecords; 55d720945f2be5ea5fe0faf67e67d9ea0e184eba67Alex Yakavenkaimport com.android.internal.telephony.uicc.IsimUiccRecords; 56d720945f2be5ea5fe0faf67e67d9ea0e184eba67Alex Yakavenkaimport com.android.internal.telephony.uicc.SIMRecords; 57d720945f2be5ea5fe0faf67e67d9ea0e184eba67Alex Yakavenkaimport com.android.internal.telephony.uicc.UiccCardApplication; 58c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport com.android.internal.telephony.uicc.UiccController; 59a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport com.android.internal.telephony.ServiceStateTracker; 60a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport com.android.internal.telephony.TelephonyIntents; 61a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport com.android.internal.telephony.TelephonyProperties; 62c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 63c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport java.io.FileDescriptor; 64c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savilleimport java.io.PrintWriter; 65c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 66a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport static com.android.internal.telephony.TelephonyProperties.PROPERTY_ICC_OPERATOR_ALPHA; 67a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport static com.android.internal.telephony.TelephonyProperties.PROPERTY_ICC_OPERATOR_ISO_COUNTRY; 68a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport static com.android.internal.telephony.TelephonyProperties.PROPERTY_ICC_OPERATOR_NUMERIC; 69a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 70a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport static com.android.internal.telephony.PhoneConstants.EVENT_SUBSCRIPTION_ACTIVATED; 71a8467dd0c524787104b1ccdddc5e8af10ba729edWink Savilleimport static com.android.internal.telephony.PhoneConstants.EVENT_SUBSCRIPTION_DEACTIVATED; 72a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 73c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Savillepublic class CDMALTEPhone extends CDMAPhone { 74cbaa45bbf2cab852b6c9c3a887e9f803d4e857eaWink Saville static final String LOG_LTE_TAG = "CDMALTEPhone"; 75c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville private static final boolean DBG = true; 76c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 77e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka /** CdmaLtePhone in addition to RuimRecords available from 78e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka * PhoneBase needs access to SIMRecords and IsimUiccRecords 79e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka */ 80e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka private SIMRecords mSimRecords; 81e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka private IsimUiccRecords mIsimUiccRecords; 82e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka 83c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville // Constructors 84a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public CDMALTEPhone(Context context, CommandsInterface ci, PhoneNotifier notifier, 85a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville int phoneId) { 86a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville this(context, ci, notifier, false, phoneId); 87a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 88a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 89a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public CDMALTEPhone(Context context, CommandsInterface ci, PhoneNotifier notifier, 90a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville boolean unitTestMode, int phoneId) { 91a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville super(context, ci, notifier, phoneId); 92a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 93a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville Rlog.d(LOG_TAG, "CDMALTEPhone: constructor: sub = " + mPhoneId); 94a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 95a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mDcTracker = new DcTracker(this); 96a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 97a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 98a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 99a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // Constructors 100c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public CDMALTEPhone(Context context, CommandsInterface ci, PhoneNotifier notifier) { 101c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville super(context, ci, notifier, false); 102c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 103c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 104c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 105a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public void handleMessage (Message msg) { 106a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville switch (msg.what) { 107a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville case EVENT_SUBSCRIPTION_ACTIVATED: 108a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville log("EVENT_SUBSCRIPTION_ACTIVATED"); 109a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville onSubscriptionActivated(); 110a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville break; 111a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 112a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville case EVENT_SUBSCRIPTION_DEACTIVATED: 113a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville log("EVENT_SUBSCRIPTION_DEACTIVATED"); 114a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville onSubscriptionDeactivated(); 115a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville break; 116a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 117a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville default: 118a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville super.handleMessage(msg); 119a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 120a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 121a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 122a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville @Override 123c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville protected void initSstIcc() { 124c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville mSST = new CdmaLteServiceStateTracker(this); 125c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 126c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 127c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 128c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public void dispose() { 129c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville synchronized(PhoneProxy.lockForRadioTechnologyChange) { 130c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville super.dispose(); 131c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 132c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 133c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 134c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 135c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public void removeReferences() { 136c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville super.removeReferences(); 137c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 138c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 139c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 140c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public PhoneConstants.DataState getDataConnectionState(String apnType) { 141c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville PhoneConstants.DataState ret = PhoneConstants.DataState.DISCONNECTED; 142c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 143c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville if (mSST == null) { 144c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville // Radio Technology Change is ongoing, dispose() and 145c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville // removeReferences() have already been called 146c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 147c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville ret = PhoneConstants.DataState.DISCONNECTED; 148454b1dfd508844b42eb775e4ab2359be74d3672bWink Saville } else if (mDcTracker.isApnTypeEnabled(apnType) == false) { 149c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville ret = PhoneConstants.DataState.DISCONNECTED; 150c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } else { 151454b1dfd508844b42eb775e4ab2359be74d3672bWink Saville switch (mDcTracker.getState(apnType)) { 152c6bbea82bf74ebb492508199b6f3e172b7ce860aWink Saville case RETRYING: 153c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville case FAILED: 154c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville case IDLE: 155c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville ret = PhoneConstants.DataState.DISCONNECTED; 156c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville break; 157c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 158c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville case CONNECTED: 159c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville case DISCONNECTING: 16022d85a8e3a575a6d01d2c788587971657dfe20c6Wink Saville if (mCT.mState != PhoneConstants.State.IDLE && 161c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville !mSST.isConcurrentVoiceAndDataAllowed()) { 162c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville ret = PhoneConstants.DataState.SUSPENDED; 163c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } else { 164c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville ret = PhoneConstants.DataState.CONNECTED; 165c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 166c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville break; 167c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 168c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville case CONNECTING: 169c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville case SCANNING: 170c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville ret = PhoneConstants.DataState.CONNECTING; 171c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville break; 172c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 173c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 174c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 175c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville log("getDataConnectionState apnType=" + apnType + " ret=" + ret); 176c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville return ret; 177c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 178c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 179ce06370fc58f59abda3cb072326e9425da3d755dWink Saville /** 180ce06370fc58f59abda3cb072326e9425da3d755dWink Saville * Sets the "current" field in the telephony provider according to the 181ce06370fc58f59abda3cb072326e9425da3d755dWink Saville * build-time operator numeric property 182ce06370fc58f59abda3cb072326e9425da3d755dWink Saville * 183ce06370fc58f59abda3cb072326e9425da3d755dWink Saville * @return true for success; false otherwise. 184ce06370fc58f59abda3cb072326e9425da3d755dWink Saville */ 185ce06370fc58f59abda3cb072326e9425da3d755dWink Saville @Override 186ce06370fc58f59abda3cb072326e9425da3d755dWink Saville boolean updateCurrentCarrierInProvider(String operatorNumeric) { 187ce06370fc58f59abda3cb072326e9425da3d755dWink Saville boolean retVal; 188a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville if (mUiccController.getUiccCardApplication(mPhoneId, UiccController.APP_FAM_3GPP) == null) { 189ce06370fc58f59abda3cb072326e9425da3d755dWink Saville if (DBG) log("updateCurrentCarrierInProvider APP_FAM_3GPP == null"); 190ce06370fc58f59abda3cb072326e9425da3d755dWink Saville retVal = super.updateCurrentCarrierInProvider(operatorNumeric); 191ce06370fc58f59abda3cb072326e9425da3d755dWink Saville } else { 192ce06370fc58f59abda3cb072326e9425da3d755dWink Saville if (DBG) log("updateCurrentCarrierInProvider not updated"); 193ce06370fc58f59abda3cb072326e9425da3d755dWink Saville retVal = true; 194ce06370fc58f59abda3cb072326e9425da3d755dWink Saville } 195ce06370fc58f59abda3cb072326e9425da3d755dWink Saville if (DBG) log("updateCurrentCarrierInProvider X retVal=" + retVal); 196ce06370fc58f59abda3cb072326e9425da3d755dWink Saville return retVal; 197ce06370fc58f59abda3cb072326e9425da3d755dWink Saville } 198ce06370fc58f59abda3cb072326e9425da3d755dWink Saville 199c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 200c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public boolean updateCurrentCarrierInProvider() { 201a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville long currentDds = SubscriptionManager.getDefaultDataSubId(); 202a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville String operatorNumeric = getOperatorNumeric(); 203a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 204a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville Rlog.d(LOG_TAG, "updateCurrentCarrierInProvider: mSubscription = " + getSubId() 205a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville + " currentDds = " + currentDds + " operatorNumeric = " + operatorNumeric); 206a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 207a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville if (!TextUtils.isEmpty(operatorNumeric) && (getSubId() == currentDds)) { 208c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville try { 209c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville Uri uri = Uri.withAppendedPath(Telephony.Carriers.CONTENT_URI, "current"); 210c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville ContentValues map = new ContentValues(); 211c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville map.put(Telephony.Carriers.NUMERIC, operatorNumeric); 212c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville mContext.getContentResolver().insert(uri, map); 213c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville return true; 214c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } catch (SQLException e) { 215a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville Rlog.e(LOG_TAG, "Can't store current operator", e); 216c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 217c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 218c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville return false; 219c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 220c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 221c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville // return IMSI from USIM as subscriber ID. 222c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 223c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public String getSubscriberId() { 224e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka return (mSimRecords != null) ? mSimRecords.getIMSI() : ""; 225c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 226c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 2270e4abef0d7e978d4c3dea5199f451a1c69158d03Sungmin Choi // return GID1 from USIM 2280e4abef0d7e978d4c3dea5199f451a1c69158d03Sungmin Choi @Override 2290e4abef0d7e978d4c3dea5199f451a1c69158d03Sungmin Choi public String getGroupIdLevel1() { 2300e4abef0d7e978d4c3dea5199f451a1c69158d03Sungmin Choi return (mSimRecords != null) ? mSimRecords.getGid1() : ""; 2310e4abef0d7e978d4c3dea5199f451a1c69158d03Sungmin Choi } 2320e4abef0d7e978d4c3dea5199f451a1c69158d03Sungmin Choi 233c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 234c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public String getImei() { 235c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville return mImei; 236c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 237c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 238c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 239c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public String getDeviceSvn() { 240c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville return mImeiSv; 241c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 242c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 243c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 244c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public IsimRecords getIsimRecords() { 245e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka return mIsimUiccRecords; 246c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 247c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 248c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 249c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public String getMsisdn() { 250e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka return (mSimRecords != null) ? mSimRecords.getMsisdnNumber() : null; 251c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 252c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 253c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 254c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public void getAvailableNetworks(Message response) { 25522d85a8e3a575a6d01d2c788587971657dfe20c6Wink Saville mCi.getAvailableNetworks(response); 256c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 257c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 258c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 259e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka protected void onUpdateIccAvailability() { 260e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka if (mUiccController == null ) { 261bb36adde615d3d85fa0fc23935197c6bc6a799edAlex Yakavenka return; 262bb36adde615d3d85fa0fc23935197c6bc6a799edAlex Yakavenka } 263bb36adde615d3d85fa0fc23935197c6bc6a799edAlex Yakavenka 264a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville UiccCardApplication newUiccApplication = getUiccCardApplication(); 265a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 266a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville UiccCardApplication app = mUiccApplication.get(); 267a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville if (app != newUiccApplication) { 268a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville if (app != null) { 269a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville log("Removing stale icc objects."); 270a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville if (mIccRecords.get() != null) { 271a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville unregisterForRuimRecordEvents(); 272a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 273a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mIccRecords.set(null); 274a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mUiccApplication.set(null); 275a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 276a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville if (newUiccApplication != null) { 277a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville log("New Uicc application found"); 278a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mUiccApplication.set(newUiccApplication); 279a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mIccRecords.set(newUiccApplication.getIccRecords()); 280a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville registerForRuimRecordEvents(); 281a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 282a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 283a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 284a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville super.onUpdateIccAvailability(); 285a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 286e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka 287a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville @Override 288a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville protected void init(Context context, PhoneNotifier notifier) { 289a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCi.setPhoneType(PhoneConstants.PHONE_TYPE_CDMA); 290a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCT = new CdmaCallTracker(this); 291a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCdmaSSM = CdmaSubscriptionSourceManager.getInstance(context, mCi, this, 292a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville EVENT_CDMA_SUBSCRIPTION_SOURCE_CHANGED, null); 293a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mRuimPhoneBookInterfaceManager = new RuimPhoneBookInterfaceManager(this); 294a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mSubInfo = new PhoneSubInfo(this); 295a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mEriManager = new EriManager(this, context, EriManager.ERI_FROM_XML); 296a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 297a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCi.registerForAvailable(this, EVENT_RADIO_AVAILABLE, null); 298a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCi.registerForOffOrNotAvailable(this, EVENT_RADIO_OFF_OR_NOT_AVAILABLE, null); 299a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCi.registerForOn(this, EVENT_RADIO_ON, null); 300a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCi.setOnSuppServiceNotification(this, EVENT_SSN, null); 301a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mSST.registerForNetworkAttached(this, EVENT_REGISTERED_TO_NETWORK, null); 302a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCi.setEmergencyCallbackMode(this, EVENT_EMERGENCY_CALLBACK_MODE_ENTER, null); 303a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCi.registerForExitEmergencyCallbackMode(this, EVENT_EXIT_EMERGENCY_CALLBACK_RESPONSE, 304a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville null); 305a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 306a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville PowerManager pm 307a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville = (PowerManager) context.getSystemService(Context.POWER_SERVICE); 308a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mWakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK,LOG_TAG); 309a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 310a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // This is needed to handle phone process crashes 311a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville String inEcm = SystemProperties.get(TelephonyProperties.PROPERTY_INECM_MODE, "false"); 312a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mIsPhoneInEcmState = inEcm.equals("true"); 313a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville if (mIsPhoneInEcmState) { 314a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // Send a message which will invoke handleExitEmergencyCallbackMode 315a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCi.exitEmergencyCallbackMode(obtainMessage(EVENT_EXIT_EMERGENCY_CALLBACK_RESPONSE)); 316bb36adde615d3d85fa0fc23935197c6bc6a799edAlex Yakavenka } 317e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka 318a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // get the string that specifies the carrier OTA Sp number 319a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mCarrierOtaSpNumSchema = SystemProperties.get( 320a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville TelephonyProperties.PROPERTY_OTASP_NUM_SCHEMA,""); 321a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 322a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // Notify voicemails. 323a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville notifier.notifyMessageWaitingChanged(this); 324a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville setProperties(); 325a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 326a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 327a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville private void onSubscriptionActivated() { 328a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville// mSubscriptionData = SubscriptionManager.getCurrentSubscription(mSubscription); 329a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 330a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville log("SUBSCRIPTION ACTIVATED : slotId : " + mSubscriptionData.slotId 331a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville + " appid : " + mSubscriptionData.m3gpp2Index 332a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville + " subId : " + mSubscriptionData.subId 333a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville + " subStatus : " + mSubscriptionData.subStatus); 334a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 335a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // Make sure properties are set for proper subscription. 336a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville setProperties(); 337a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 338a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville onUpdateIccAvailability(); 339a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mSST.sendMessage(mSST.obtainMessage(ServiceStateTracker.EVENT_ICC_CHANGED)); 340a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville ((CdmaLteServiceStateTracker)mSST).updateCdmaSubscription(); 341a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville ((DcTracker)mDcTracker).updateRecords(); 342a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 343a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 344a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville private void onSubscriptionDeactivated() { 345a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville log("SUBSCRIPTION DEACTIVATED"); 346a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // resetSubSpecifics 347a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville mSubscriptionData = null; 348a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 349a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 350a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // Set the properties per subscription 351a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville private void setProperties() { 352a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville //Change the system property 353a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville setSystemProperty(TelephonyProperties.CURRENT_ACTIVE_PHONE, 354a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville new Integer(PhoneConstants.PHONE_TYPE_CDMA).toString()); 355a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // Sets operator alpha property by retrieving from build-time system property 356a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville String operatorAlpha = SystemProperties.get("ro.cdma.home.operator.alpha"); 357b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal if (!TextUtils.isEmpty(operatorAlpha)) { 358b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal setSystemProperty(PROPERTY_ICC_OPERATOR_ALPHA, operatorAlpha); 359b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal } 360a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 361a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // Sets operator numeric property by retrieving from build-time system property 362a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville String operatorNumeric = SystemProperties.get(PROPERTY_CDMA_HOME_OPERATOR_NUMERIC); 363a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville log("update icc_operator_numeric=" + operatorNumeric); 364b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal if (!TextUtils.isEmpty(operatorNumeric)) { 365b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal setSystemProperty(PROPERTY_ICC_OPERATOR_NUMERIC, operatorNumeric); 366b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal // Sets iso country property by retrieving from build-time system property 367b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal setIsoCountryProperty(operatorNumeric); 368b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal // Updates MCC MNC device configuration information 369b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal log("update mccmnc=" + operatorNumeric); 370b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal MccTable.updateMccMncConfiguration(mContext, operatorNumeric, false); 371b93bb3538c55f173f94a4ee7510d9d1521d8f731Shishir Agrawal } 372a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville // Sets current entry in the telephony carrier table 373a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville updateCurrentCarrierInProvider(); 374a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 375a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 376a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville @Override 377a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville protected UiccCardApplication getUiccCardApplication() { 378a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville return mUiccController.getUiccCardApplication(mPhoneId, UiccController.APP_FAM_3GPP2); 379a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 380a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 381a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville @Override 382a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public void setSystemProperty(String property, String value) { 383a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville if(getUnitTestMode()) { 384a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville return; 385e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka } 386a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville TelephonyManager.setTelephonyProperty(property, getSubId(), value); 387a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 388a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 389a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public String getSystemProperty(String property, String defValue) { 390a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville if(getUnitTestMode()) { 391a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville return null; 392a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 393a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville return TelephonyManager.getTelephonyProperty(property, getSubId(), defValue); 394a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 395a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 396a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public void updateDataConnectionTracker() { 397a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville ((DcTracker)mDcTracker).update(); 398a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 399a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 400a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public void setInternalDataEnabled(boolean enable, Message onCompleteMsg) { 401a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville ((DcTracker)mDcTracker) 402a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville .setInternalDataEnabled(enable, onCompleteMsg); 403a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 404a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 405a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public boolean setInternalDataEnabledFlag(boolean enable) { 406a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville return ((DcTracker)mDcTracker) 407a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville .setInternalDataEnabledFlag(enable); 408a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 409a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 410a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville /** 411a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville * @return operator numeric. 412a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville */ 413a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public String getOperatorNumeric() { 414a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville String operatorNumeric = null; 415a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 416a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville if (mCdmaSubscriptionSource == CDMA_SUBSCRIPTION_NV) { 417a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville operatorNumeric = SystemProperties.get("ro.cdma.home.operator.numeric"); 418a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } else if (mCdmaSubscriptionSource == CDMA_SUBSCRIPTION_RUIM_SIM 419a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville && mIccRecords != null && mIccRecords.get() != null) { 420a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville operatorNumeric = mIccRecords.get().getOperatorNumeric(); 421a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } else { 422a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville Rlog.e(LOG_TAG, "getOperatorNumeric: Cannot retrieve operatorNumeric:" 423a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville + " mCdmaSubscriptionSource = " + mCdmaSubscriptionSource + " mIccRecords = " 424a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville + ((mIccRecords != null) && (mIccRecords.get() != null) 425a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville ? mIccRecords.get().getRecordsLoaded() 426a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville : null)); 427e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka } 428e287feac673ff68565b766e0e463d105fa9cef9dAlex Yakavenka 429a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville Rlog.d(LOG_TAG, "getOperatorNumeric: mCdmaSubscriptionSource = " + mCdmaSubscriptionSource 430a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville + " operatorNumeric = " + operatorNumeric); 431a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 432a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville return operatorNumeric; 433a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 434a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public void registerForAllDataDisconnected(Handler h, int what, Object obj) { 435a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville ((DcTracker)mDcTracker) 436a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville .registerForAllDataDisconnected(h, what, obj); 437a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville } 438a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville 439a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville public void unregisterForAllDataDisconnected(Handler h) { 440a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville ((DcTracker)mDcTracker) 441a8467dd0c524787104b1ccdddc5e8af10ba729edWink Saville .unregisterForAllDataDisconnected(h); 442bb36adde615d3d85fa0fc23935197c6bc6a799edAlex Yakavenka } 443bb36adde615d3d85fa0fc23935197c6bc6a799edAlex Yakavenka 444bb36adde615d3d85fa0fc23935197c6bc6a799edAlex Yakavenka @Override 445c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville protected void log(String s) { 446cbaa45bbf2cab852b6c9c3a887e9f803d4e857eaWink Saville Rlog.d(LOG_LTE_TAG, s); 447cbaa45bbf2cab852b6c9c3a887e9f803d4e857eaWink Saville } 448cbaa45bbf2cab852b6c9c3a887e9f803d4e857eaWink Saville 449cbaa45bbf2cab852b6c9c3a887e9f803d4e857eaWink Saville protected void loge(String s) { 450cbaa45bbf2cab852b6c9c3a887e9f803d4e857eaWink Saville Rlog.e(LOG_LTE_TAG, s); 451c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 452c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville 453cbaa45bbf2cab852b6c9c3a887e9f803d4e857eaWink Saville protected void loge(String s, Throwable e) { 454cbaa45bbf2cab852b6c9c3a887e9f803d4e857eaWink Saville Rlog.e(LOG_LTE_TAG, s, e); 455f61aaae6608243be4e0da97a56ff9fed488cb173Shishir Agrawal } 456cbaa45bbf2cab852b6c9c3a887e9f803d4e857eaWink Saville 457c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville @Override 458c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville public void dump(FileDescriptor fd, PrintWriter pw, String[] args) { 459c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville pw.println("CDMALTEPhone extends:"); 460c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville super.dump(fd, pw, args); 461c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville } 462c38bb60d867c5d61d90b7179a9ed2b2d1848124fWink Saville} 463