19066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project/* 29066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Copyright (C) 2007 The Android Open Source Project 39066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * 49066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Licensed under the Apache License, Version 2.0 (the "License"); 59066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * you may not use this file except in compliance with the License. 69066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * You may obtain a copy of the License at 79066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * 89066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * http://www.apache.org/licenses/LICENSE-2.0 99066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * 109066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Unless required by applicable law or agreed to in writing, software 119066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * distributed under the License is distributed on an "AS IS" BASIS, 129066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 139066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * See the License for the specific language governing permissions and 149066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * limitations under the License. 159066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 169066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 179066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Projectpackage com.android.internal.telephony; 189066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 19485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yenimport android.app.PendingIntent; 2063c4c06be44fe8bd4506e6f9f57361d31e947c21Shishir Agrawalimport android.content.Intent; 219066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Projectimport android.os.Bundle; 22010bf374d8145528f8733dfa6ef101b15de23a8dAdam Lesinskiimport android.os.ResultReceiver; 23740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chenimport android.net.Uri; 2464997623bfa04e80064b6056fab0fb23144acb44Meng Wangimport android.service.carrier.CarrierIdentifier; 25ed4ca5ca2c40ed2c838aaf483fcd58abdfa0ff08Santos Cordonimport android.telecom.PhoneAccount; 26740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chenimport android.telecom.PhoneAccountHandle; 27fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Savilleimport android.telephony.CellInfo; 288347c3898dfca9db048aa0feb0e52a6b55a205efSooraj Sasindranimport android.telephony.ClientRequestStats; 29a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawalimport android.telephony.IccOpenLogicalChannelResponse; 3039daf8d6f14a01d2854352fe08d14195f7a2056bJack Yuimport android.telephony.ModemActivityInfo; 31a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawalimport android.telephony.NeighboringCellInfo; 322af2d57d578e0c3a2740628e7c6336b19961cc49Wink Savilleimport android.telephony.RadioAccessFamily; 3339daf8d6f14a01d2854352fe08d14195f7a2056bJack Yuimport android.telephony.ServiceState; 3406e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padaweimport android.telephony.TelephonyHistogram; 3567ab168b78782c4de5de3f44817961468533757cTa-wei Yenimport android.telephony.VisualVoicemailSmsFilterSettings; 36e37ebbffb01042b667633362459c3a069575ad46Brad Ebingerimport com.android.ims.internal.IImsServiceController; 37e37ebbffb01042b667633362459c3a069575ad46Brad Ebingerimport com.android.ims.internal.IImsServiceFeatureListener; 38d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawalimport com.android.internal.telephony.CellNetworkScanResult; 39d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawalimport com.android.internal.telephony.OperatorInfo; 4006e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padawe 41a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawalimport java.util.List; 429066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 43aae9216320328e6b865725219a31a029ea46c1b0Sailesh Nepal 449066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project/** 45767a662ecde33c3979bf02b793d392aca0403162Wink Saville * Interface used to interact with the phone. Mostly this is used by the 469066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * TelephonyManager class. A few places are still using this directly. 474a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee * Please clean them up if possible and use TelephonyManager instead. 489066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * 499066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * {@hide} 509066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 519066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Projectinterface ITelephony { 529066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 539066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 549066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Dial a number. This doesn't place the call. It displays 559066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * the Dialer screen. 569066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @param number the number to be dialed. If null, this 579066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * would display the Dialer screen with no number pre-filled. 589066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 599066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project void dial(String number); 609066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 619066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 629066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Place a call to the specified number. 6316a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov * @param callingPackage The package making the call. 649066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @param number the number to be called. 659066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 66f265ea9d8307282ff1da3915978625a94fc2859eDianne Hackborn void call(String callingPackage, String number); 679066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 689066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 694d396052deb54399cbadbeb8abd873df6f3af342Jeff Brown * End call if there is a call in progress, otherwise does nothing. 709066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * 719066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @return whether it hung up 729066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 739066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project boolean endCall(); 749066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 759066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 76fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * End call on particular subId or go to the Home screen 77fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 78fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return whether it hung up 79fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 8063f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville boolean endCallForSubscriber(int subId); 81fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 82fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 839066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Answer the currently-ringing call. 849066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * 859066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * If there's already a current active call, that call will be 869066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * automatically put on hold. If both lines are currently in use, the 879066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * current active call will be ended. 889066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * 899066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * TODO: provide a flag to let the caller specify what policy to use 909066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * if both lines are in use. (The current behavior is hardwired to 919066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * "answer incoming, end ongoing", which is how the CALL button 929066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * is specced to behave.) 939066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * 949066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * TODO: this should be a oneway call (especially since it's called 959066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * directly from the key queue thread). 969066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 979066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project void answerRingingCall(); 989066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 999066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 10005e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * Answer the currently-ringing call on particular subId . 10105e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * 10205e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * If there's already a current active call, that call will be 10305e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * automatically put on hold. If both lines are currently in use, the 10405e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * current active call will be ended. 10505e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * 10605e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * TODO: provide a flag to let the caller specify what policy to use 10705e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * if both lines are in use. (The current behavior is hardwired to 10805e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * "answer incoming, end ongoing", which is how the CALL button 10905e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * is specced to behave.) 11005e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * 11105e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * TODO: this should be a oneway call (especially since it's called 11205e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville * directly from the key queue thread). 11305e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville */ 11463f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville void answerRingingCallForSubscriber(int subId); 11505e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville 11605e6dde3a0b9ba1eb3d13d511fe2e27a0d10c851Wink Saville /** 1179066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Silence the ringer if an incoming call is currently ringing. 1189066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * (If vibrating, stop the vibrator also.) 1199066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * 1209066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * It's safe to call this if the ringer has already been silenced, or 1219066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * even if there's no incoming call. (If so, this method will do nothing.) 1229066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * 1239066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * TODO: this should be a oneway call too (see above). 1249066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * (Actually *all* the methods here that return void can 1259066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * probably be oneway.) 1269066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 1279066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project void silenceRinger(); 1289066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 1299066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 1309066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Check if we are in either an active or holding call 1316e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the package making the call. 1329066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @return true if the phone state is OFFHOOK. 1339066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 1346e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt boolean isOffhook(String callingPackage); 1359066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 1369066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 137fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Check if a particular subId has an active or holding call 138fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * 139fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 1406e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the package making the call. 141fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return true if the phone state is OFFHOOK. 142fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 1436e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt boolean isOffhookForSubscriber(int subId, String callingPackage); 144fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 145fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 146fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Check if an incoming phone call is ringing or call waiting 147fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * on a particular subId. 148fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * 149fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 1506e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the package making the call. 151fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return true if the phone state is RINGING. 152fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 1536e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt boolean isRingingForSubscriber(int subId, String callingPackage); 154fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 155fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 1569066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Check if an incoming phone call is ringing or call waiting. 1576e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the package making the call. 1589066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @return true if the phone state is RINGING. 1599066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 1606e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt boolean isRinging(String callingPackage); 1619066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 1629066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 1639066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Check if the phone is idle. 1646e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the package making the call. 1659066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @return true if the phone state is IDLE. 1669066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 1676e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt boolean isIdle(String callingPackage); 1689066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 1699066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 170fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Check if the phone is idle on a particular subId. 171fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * 172fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 1736e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the package making the call. 174fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return true if the phone state is IDLE. 175fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 1766e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt boolean isIdleForSubscriber(int subId, String callingPackage); 177fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 178fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 1799066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Check to see if the radio is on or not. 1806e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the package making the call. 1819066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @return returns true if the radio is on. 1829066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 1836e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt boolean isRadioOn(String callingPackage); 1849066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 1859066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 186fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Check to see if the radio is on or not on particular subId. 187fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 1886e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the package making the call. 189fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return returns true if the radio is on. 190fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 1916e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt boolean isRadioOnForSubscriber(int subId, String callingPackage); 192fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 193fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 1949066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Supply a pin to unlock the SIM. Blocks until a result is determined. 1959066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @param pin The pin to check. 1969066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @return whether the operation was a success. 1979066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 1989066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project boolean supplyPin(String pin); 1999066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 2009066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 201fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Supply a pin to unlock the SIM for particular subId. 202fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Blocks until a result is determined. 203fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param pin The pin to check. 204fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 205fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return whether the operation was a success. 206fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 20763f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville boolean supplyPinForSubscriber(int subId, String pin); 208fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 209fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 21098c7781ca89348992e3cb455e83cbc774bbe4d3eJohn Wang * Supply puk to unlock the SIM and set SIM pin to new pin. 21198c7781ca89348992e3cb455e83cbc774bbe4d3eJohn Wang * Blocks until a result is determined. 21298c7781ca89348992e3cb455e83cbc774bbe4d3eJohn Wang * @param puk The puk to check. 21398c7781ca89348992e3cb455e83cbc774bbe4d3eJohn Wang * pin The new pin to be set in SIM 21498c7781ca89348992e3cb455e83cbc774bbe4d3eJohn Wang * @return whether the operation was a success. 21598c7781ca89348992e3cb455e83cbc774bbe4d3eJohn Wang */ 21698c7781ca89348992e3cb455e83cbc774bbe4d3eJohn Wang boolean supplyPuk(String puk, String pin); 21798c7781ca89348992e3cb455e83cbc774bbe4d3eJohn Wang 21898c7781ca89348992e3cb455e83cbc774bbe4d3eJohn Wang /** 219fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Supply puk to unlock the SIM and set SIM pin to new pin. 220fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Blocks until a result is determined. 221fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param puk The puk to check. 222fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * pin The new pin to be set in SIM 223fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 224fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return whether the operation was a success. 225fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 22663f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville boolean supplyPukForSubscriber(int subId, String puk, String pin); 227fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 228fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 229b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * Supply a pin to unlock the SIM. Blocks until a result is determined. 230b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * Returns a specific success/error code. 231b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * @param pin The pin to check. 232b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * @return retValue[0] = Phone.PIN_RESULT_SUCCESS on success. Otherwise error code 233b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * retValue[1] = number of attempts remaining if known otherwise -1 234b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville */ 235b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville int[] supplyPinReportResult(String pin); 236b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville 237b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville /** 238fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Supply a pin to unlock the SIM. Blocks until a result is determined. 239fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns a specific success/error code. 240fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param pin The pin to check. 241fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return retValue[0] = Phone.PIN_RESULT_SUCCESS on success. Otherwise error code 242fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * retValue[1] = number of attempts remaining if known otherwise -1 243fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 24463f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville int[] supplyPinReportResultForSubscriber(int subId, String pin); 245fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 246fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 247b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * Supply puk to unlock the SIM and set SIM pin to new pin. 248b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * Blocks until a result is determined. 249b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * Returns a specific success/error code 250b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * @param puk The puk to check 251b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * pin The pin to check. 252b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * @return retValue[0] = Phone.PIN_RESULT_SUCCESS on success. Otherwise error code 253b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville * retValue[1] = number of attempts remaining if known otherwise -1 254b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville */ 255b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville int[] supplyPukReportResult(String puk, String pin); 256b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville 257b896b9f74225d61af67c2661f44eceadb9e22013Wink Saville /** 258fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Supply puk to unlock the SIM and set SIM pin to new pin. 259fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Blocks until a result is determined. 260fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns a specific success/error code 261fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param puk The puk to check 262fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * pin The pin to check. 263fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return retValue[0] = Phone.PIN_RESULT_SUCCESS on success. Otherwise error code 264fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * retValue[1] = number of attempts remaining if known otherwise -1 265fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 26663f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville int[] supplyPukReportResultForSubscriber(int subId, String puk, String pin); 267fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 268fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 2699066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Handles PIN MMI commands (PIN/PIN2/PUK/PUK2), which are initiated 2709066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * without SEND (so <code>dial</code> is not appropriate). 271767a662ecde33c3979bf02b793d392aca0403162Wink Saville * 2729066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @param dialString the MMI command to be executed. 2739066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * @return true if MMI command is executed. 2749066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 2759066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project boolean handlePinMmi(String dialString); 2769066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 27719ba736c22869ec678ce0a79858ab3624fedee1bpkanwar 27819ba736c22869ec678ce0a79858ab3624fedee1bpkanwar /** 27919ba736c22869ec678ce0a79858ab3624fedee1bpkanwar * Handles USSD commands. 28019ba736c22869ec678ce0a79858ab3624fedee1bpkanwar * 281d570f63b72507a4c2a6d53d941f6d67dd72711e5pkanwar * @param subId The subscription to use. 28219ba736c22869ec678ce0a79858ab3624fedee1bpkanwar * @param ussdRequest the USSD command to be executed. 28319ba736c22869ec678ce0a79858ab3624fedee1bpkanwar * @param wrappedCallback receives a callback result. 28419ba736c22869ec678ce0a79858ab3624fedee1bpkanwar */ 285d570f63b72507a4c2a6d53d941f6d67dd72711e5pkanwar void handleUssdRequest(int subId, String ussdRequest, in ResultReceiver wrappedCallback); 28619ba736c22869ec678ce0a79858ab3624fedee1bpkanwar 2879066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 288fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Handles PIN MMI commands (PIN/PIN2/PUK/PUK2), which are initiated 289fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * without SEND (so <code>dial</code> is not appropriate) for 290fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * a particular subId. 291fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param dialString the MMI command to be executed. 292fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 293fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return true if MMI command is executed. 294fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 29563f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville boolean handlePinMmiForSubscriber(int subId, String dialString); 296fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 297fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 2989066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Toggles the radio on or off. 2999066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 3009066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project void toggleRadioOnOff(); 3019066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 3029066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 303fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Toggles the radio on or off on particular subId. 304fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 305fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 30663f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville void toggleRadioOnOffForSubscriber(int subId); 307fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 308fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 3099066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Set the radio to on or off 3109066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 3119066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project boolean setRadio(boolean turnOn); 3129066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 3139066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 314fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Set the radio to on or off on particular subId. 315fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 316fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 31763f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville boolean setRadioForSubscriber(int subId, boolean turnOn); 318fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 319fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 32045ac9645da0ceafbae8c00b0dd0a09800fdcefdfWink Saville * Set the radio to on or off unconditionally 32145ac9645da0ceafbae8c00b0dd0a09800fdcefdfWink Saville */ 32245ac9645da0ceafbae8c00b0dd0a09800fdcefdfWink Saville boolean setRadioPower(boolean turnOn); 32345ac9645da0ceafbae8c00b0dd0a09800fdcefdfWink Saville 32445ac9645da0ceafbae8c00b0dd0a09800fdcefdfWink Saville /** 3259066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Request to update location information in service state 3269066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 3279066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project void updateServiceLocation(); 3289066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 3299066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 330fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Request to update location information for a subscrition in service state 331fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 332fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 33363f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville void updateServiceLocationForSubscriber(int subId); 334fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 335fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 3369066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Enable location update notifications. 3379066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 3389066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project void enableLocationUpdates(); 3399066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 3409066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 341fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Enable location update notifications. 342fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 343fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 34463f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville void enableLocationUpdatesForSubscriber(int subId); 345fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 346fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 3479066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Disable location update notifications. 3489066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 3499066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project void disableLocationUpdates(); 3509066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 3519066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 352fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Disable location update notifications. 353fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 354fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 35563f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville void disableLocationUpdatesForSubscriber(int subId); 356fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 357fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 3589066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Allow mobile data connections. 3599066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 3609066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project boolean enableDataConnectivity(); 3619066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 3629066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 3639066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Disallow mobile data connections. 3649066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 3659066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project boolean disableDataConnectivity(); 3669066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 3679066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 3689066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Report whether data connectivity is possible. 3699066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 3709066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project boolean isDataConnectivityPossible(); 3719066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 372275b5635ad98a411d511894e98f80e8b8bc41799Svetoslav Bundle getCellLocation(String callingPkg); 3739066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 3749066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project /** 3759066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project * Returns the neighboring cell information of the device. 3769066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project */ 377f265ea9d8307282ff1da3915978625a94fc2859eDianne Hackborn List<NeighboringCellInfo> getNeighboringCellInfo(String callingPkg); 3789066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project 3799066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project int getCallState(); 380fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 381fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 382dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * Returns the call state for a slot. 383fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 3847e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe int getCallStateForSlot(int slotIndex); 385fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 3869066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project int getDataActivity(); 3879066cfe9886ac131c34d59ed0e2d287b0e3c0087The Android Open Source Project int getDataState(); 388767a662ecde33c3979bf02b793d392aca0403162Wink Saville 389767a662ecde33c3979bf02b793d392aca0403162Wink Saville /** 390767a662ecde33c3979bf02b793d392aca0403162Wink Saville * Returns the current active phone type as integer. 391767a662ecde33c3979bf02b793d392aca0403162Wink Saville * Returns TelephonyManager.PHONE_TYPE_CDMA if RILConstants.CDMA_PHONE 392767a662ecde33c3979bf02b793d392aca0403162Wink Saville * and TelephonyManager.PHONE_TYPE_GSM if RILConstants.GSM_PHONE 393767a662ecde33c3979bf02b793d392aca0403162Wink Saville */ 394767a662ecde33c3979bf02b793d392aca0403162Wink Saville int getActivePhoneType(); 395767a662ecde33c3979bf02b793d392aca0403162Wink Saville 396e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville /** 397dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * Returns the current active phone type as integer for particular slot. 398fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns TelephonyManager.PHONE_TYPE_CDMA if RILConstants.CDMA_PHONE 399fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * and TelephonyManager.PHONE_TYPE_GSM if RILConstants.GSM_PHONE 4007e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe * @param slotIndex - slot to query. 401fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 4027e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe int getActivePhoneTypeForSlot(int slotIndex); 403fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 404fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 405e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville * Returns the CDMA ERI icon index to display 4066e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage package making the call. 407e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville */ 4086e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt int getCdmaEriIconIndex(String callingPackage); 409e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville 410e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville /** 411fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns the CDMA ERI icon index to display on particular subId. 412fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 4136e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage package making the call. 414fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 4156e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt int getCdmaEriIconIndexForSubscriber(int subId, String callingPackage); 416fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 417fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 418e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville * Returns the CDMA ERI icon mode, 419e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville * 0 - ON 420e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville * 1 - FLASHING 4216e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage package making the call. 422e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville */ 4236e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt int getCdmaEriIconMode(String callingPackage); 424e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville 425e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville /** 426fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns the CDMA ERI icon mode on particular subId, 427fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * 0 - ON 428fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * 1 - FLASHING 429fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 4306e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage package making the call. 431fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 4326e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt int getCdmaEriIconModeForSubscriber(int subId, String callingPackage); 433fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 434fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 435e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville * Returns the CDMA ERI text, 4366e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage package making the call. 437e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville */ 4386e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt String getCdmaEriText(String callingPackage); 439e9b06d754af03faf27012fbed1e7559ec1ba7c79Wink Saville 440dda5391d5079537e275c9f4ed2637a1484d0e4e8Wink Saville /** 441fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns the CDMA ERI text for particular subId, 442fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 4436e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage package making the call. 444fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 4456e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt String getCdmaEriTextForSubscriber(int subId, String callingPackage); 446fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 447fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 4484d8ae85b5de8a90a597e4b649c6ee7208e446e3bWink Saville * Returns true if OTA service provisioning needs to run. 4494d8ae85b5de8a90a597e4b649c6ee7208e446e3bWink Saville * Only relevant on some technologies, others will always 4504d8ae85b5de8a90a597e4b649c6ee7208e446e3bWink Saville * return false. 451767be5f0b929cc1eeb8a7d5aa7a02e228053e9bbJim Miller */ 4524d8ae85b5de8a90a597e4b649c6ee7208e446e3bWink Saville boolean needsOtaServiceProvisioning(); 453767be5f0b929cc1eeb8a7d5aa7a02e228053e9bbJim Miller 454767be5f0b929cc1eeb8a7d5aa7a02e228053e9bbJim Miller /** 4555c1a63c2235c36ce0b520fa88a9d21ffe255756eShishir Agrawal * Sets the voicemail number for a particular subscriber. 4565c1a63c2235c36ce0b520fa88a9d21ffe255756eShishir Agrawal */ 4575c1a63c2235c36ce0b520fa88a9d21ffe255756eShishir Agrawal boolean setVoiceMailNumber(int subId, String alphaTag, String number); 4585c1a63c2235c36ce0b520fa88a9d21ffe255756eShishir Agrawal 45912312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu /** 46012312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu * Sets the voice activation state for a particular subscriber. 46112312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu */ 46212312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu void setVoiceActivationState(int subId, int activationState); 46312312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu 46412312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu /** 46512312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu * Sets the data activation state for a particular subscriber. 46612312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu */ 46712312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu void setDataActivationState(int subId, int activationState); 46812312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu 46912312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu /** 47012312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu * Returns the voice activation state for a particular subscriber. 47112312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu * @param subId user preferred sub 47212312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu * @param callingPackage package queries voice activation state 47312312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu */ 47412312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu int getVoiceActivationState(int subId, String callingPackage); 47512312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu 47612312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu /** 47712312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu * Returns the data activation state for a particular subscriber. 47812312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu * @param subId user preferred sub 47912312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu * @param callingPackage package queris data activation state 48012312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu */ 48112312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu int getDataActivationState(int subId, String callingPackage); 48212312f6d758ab0fcd1b5a1c7c885cf4997098402fionaxu 4835c1a63c2235c36ce0b520fa88a9d21ffe255756eShishir Agrawal /** 484dda5391d5079537e275c9f4ed2637a1484d0e4e8Wink Saville * Returns the unread count of voicemails 485dda5391d5079537e275c9f4ed2637a1484d0e4e8Wink Saville */ 486ce099c3226b33b43e0dd5d1f24347b14a2223ee1David Krause int getVoiceMessageCount(); 487dda5391d5079537e275c9f4ed2637a1484d0e4e8Wink Saville 488ebe66345e7099ca6fc95e8aa4d31a5b5cbbd6224Li Zhe /** 489fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns the unread count of voicemails for a subId. 490fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 491fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns the unread count of voicemails 492fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 49363f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville int getVoiceMessageCountForSubscriber(int subId); 494fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 495a28dcbcd871ba3bb1fce4e2e4336712272d640e7pkanwar /** 496a28dcbcd871ba3bb1fce4e2e4336712272d640e7pkanwar * Returns true if current state supports both voice and data 497a28dcbcd871ba3bb1fce4e2e4336712272d640e7pkanwar * simultaneously. This can change based on location or network condition. 498a28dcbcd871ba3bb1fce4e2e4336712272d640e7pkanwar */ 499a28dcbcd871ba3bb1fce4e2e4336712272d640e7pkanwar boolean isConcurrentVoiceAndDataAllowed(int subId); 500a28dcbcd871ba3bb1fce4e2e4336712272d640e7pkanwar 5011210f41f59a131b50e4d54f308e7d1acbe76cbeaTa-wei Yen Bundle getVisualVoicemailSettings(String callingPackage, int subId); 5021210f41f59a131b50e4d54f308e7d1acbe76cbeaTa-wei Yen 5033f5858efa0b4bbed447989dca7d2c06c51dc8d13Ta-wei Yen String getVisualVoicemailPackageName(String callingPackage, int subId); 504812188ad06660ec1b3b2b027ccfa291335021664Ta-wei Yen 505349f4eddf76d1f16966a7ae7b599e984f599cf2eTa-wei Yen // Not oneway, caller needs to make sure the vaule is set before receiving a SMS 50667ab168b78782c4de5de3f44817961468533757cTa-wei Yen void enableVisualVoicemailSmsFilter(String callingPackage, int subId, 50767ab168b78782c4de5de3f44817961468533757cTa-wei Yen in VisualVoicemailSmsFilterSettings settings); 508349f4eddf76d1f16966a7ae7b599e984f599cf2eTa-wei Yen 50967ab168b78782c4de5de3f44817961468533757cTa-wei Yen oneway void disableVisualVoicemailSmsFilter(String callingPackage, int subId); 510349f4eddf76d1f16966a7ae7b599e984f599cf2eTa-wei Yen 51167ab168b78782c4de5de3f44817961468533757cTa-wei Yen // Get settings set by the calling package 51267ab168b78782c4de5de3f44817961468533757cTa-wei Yen VisualVoicemailSmsFilterSettings getVisualVoicemailSmsFilterSettings(String callingPackage, 51367ab168b78782c4de5de3f44817961468533757cTa-wei Yen int subId); 514349f4eddf76d1f16966a7ae7b599e984f599cf2eTa-wei Yen 515485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen /** 516485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen * Get settings set by the current default dialer, Internal use only. 517485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen * Requires READ_PRIVILEGED_PHONE_STATE permission. 518485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen */ 519485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen VisualVoicemailSmsFilterSettings getActiveVisualVoicemailSmsFilterSettings(int subId); 520485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen 521485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen /** 522485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen * Send a visual voicemail SMS. Internal use only. 523485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen * Requires caller to be the default dialer and have SEND_SMS permission 524485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen */ 52549f3756b598fc0c0e9c54f92c9c26e44389af781Ta-wei Yen void sendVisualVoicemailSmsForSubscriber(in String callingPackage, in int subId, 526485d6dec93579d2186a3ecd57c2b5af4ce8e622bTa-wei Yen in String number, in int port, in String text, in PendingIntent sentIntent); 527349f4eddf76d1f16966a7ae7b599e984f599cf2eTa-wei Yen 528de56b1f00a8f8ded8bde7001cc59a2c277651ea8fionaxu // Send the special dialer code. The IPC caller must be the current default dialer. 529388eab414779124f9b07837a2a9d5e4c6c1c068cfionaxu void sendDialerSpecialCode(String callingPackageName, String inputCode); 530388eab414779124f9b07837a2a9d5e4c6c1c068cfionaxu 531fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 5326e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * Returns the network type for data transmission 5339bc8299ca0b2e8396b9f2f027c440cda164ba75eRobert Greenwalt * Legacy call, permission-free 5346e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt */ 5359bc8299ca0b2e8396b9f2f027c440cda164ba75eRobert Greenwalt int getNetworkType(); 53698c7781ca89348992e3cb455e83cbc774bbe4d3eJohn Wang 537e40f66ffc11cfc7e1bbe3e4c2ae1cf6dbc24cc17Wink Saville /** 538fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns the network type of a subId. 539fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 5406e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage package making the call. 541fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 5426e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt int getNetworkTypeForSubscriber(int subId, String callingPackage); 543fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 544fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 5456e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * Returns the network type for data transmission 5466e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage package making the call. 5476e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt */ 5486e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt int getDataNetworkType(String callingPackage); 5490dde2c20a07770bc2f1b21e49222c968f3d8b39aWink Saville 5500dde2c20a07770bc2f1b21e49222c968f3d8b39aWink Saville /** 5516e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * Returns the data network type of a subId 5526e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param subId user preferred subId. 5536e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage package making the call. 5546e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt */ 5556e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt int getDataNetworkTypeForSubscriber(int subId, String callingPackage); 556fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 557fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 558fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns the voice network type of a subId 559fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @param subId user preferred subId. 5609bc8299ca0b2e8396b9f2f027c440cda164ba75eRobert Greenwalt * @param callingPackage package making the call. 561fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Returns the network type 562fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 5639bc8299ca0b2e8396b9f2f027c440cda164ba75eRobert Greenwalt int getVoiceNetworkTypeForSubscriber(int subId, String callingPackage); 564fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 565fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 566e40f66ffc11cfc7e1bbe3e4c2ae1cf6dbc24cc17Wink Saville * Return true if an ICC card is present 567e40f66ffc11cfc7e1bbe3e4c2ae1cf6dbc24cc17Wink Saville */ 568e40f66ffc11cfc7e1bbe3e4c2ae1cf6dbc24cc17Wink Saville boolean hasIccCard(); 5695e9270bfd566c32a60dfeb34435a158eb4ceb9a9Wink Saville 5705e9270bfd566c32a60dfeb34435a158eb4ceb9a9Wink Saville /** 571fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Return true if an ICC card is present for a subId. 5727e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe * @param slotIndex user preferred slotIndex. 573fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Return true if an ICC card is present 574fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 5757e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe boolean hasIccCardUsingSlotIndex(int slotIndex); 576fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 577fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 5785e9270bfd566c32a60dfeb34435a158eb4ceb9a9Wink Saville * Return if the current radio is LTE on CDMA. This 5795e9270bfd566c32a60dfeb34435a158eb4ceb9a9Wink Saville * is a tri-state return value as for a period of time 5805e9270bfd566c32a60dfeb34435a158eb4ceb9a9Wink Saville * the mode may be unknown. 5815e9270bfd566c32a60dfeb34435a158eb4ceb9a9Wink Saville * 5826e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the calling package 5835e9270bfd566c32a60dfeb34435a158eb4ceb9a9Wink Saville * @return {@link Phone#LTE_ON_CDMA_UNKNOWN}, {@link Phone#LTE_ON_CDMA_FALSE} 5845e9270bfd566c32a60dfeb34435a158eb4ceb9a9Wink Saville * or {@link PHone#LTE_ON_CDMA_TRUE} 5855e9270bfd566c32a60dfeb34435a158eb4ceb9a9Wink Saville */ 5866e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt int getLteOnCdmaMode(String callingPackage); 587963db55d59a170f4b17ff907c96615a19ef6fe17John Wang 588963db55d59a170f4b17ff907c96615a19ef6fe17John Wang /** 589fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Return if the current radio is LTE on CDMA. This 590fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * is a tri-state return value as for a period of time 591fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * the mode may be unknown. 592fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * 5936e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the calling package 594fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return {@link Phone#LTE_ON_CDMA_UNKNOWN}, {@link Phone#LTE_ON_CDMA_FALSE} 595fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * or {@link PHone#LTE_ON_CDMA_TRUE} 596fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 5976e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt int getLteOnCdmaModeForSubscriber(int subId, String callingPackage); 598fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 599fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 600963db55d59a170f4b17ff907c96615a19ef6fe17John Wang * Returns the all observed cell information of the device. 601963db55d59a170f4b17ff907c96615a19ef6fe17John Wang */ 602275b5635ad98a411d511894e98f80e8b8bc41799Svetoslav List<CellInfo> getAllCellInfo(String callingPkg); 603094beeccf5bf6e68d73f94a1aeaeda6690f4bf06Wink Saville 604094beeccf5bf6e68d73f94a1aeaeda6690f4bf06Wink Saville /** 605094beeccf5bf6e68d73f94a1aeaeda6690f4bf06Wink Saville * Sets minimum time in milli-seconds between onCellInfoChanged 606094beeccf5bf6e68d73f94a1aeaeda6690f4bf06Wink Saville */ 607094beeccf5bf6e68d73f94a1aeaeda6690f4bf06Wink Saville void setCellInfoListRate(int rateInMillis); 608767a662ecde33c3979bf02b793d392aca0403162Wink Saville 60957f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal /** 610fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * get default sim 611fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * @return sim id 612fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 613fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville int getDefaultSim(); 614fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 615fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 61657f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * Opens a logical channel to the ICC card. 61757f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * 61857f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * Input parameters equivalent to TS 27.007 AT+CCHO command. 61957f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * 62052103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal * @param subId The subscription to use. 62157f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @param AID Application id. See ETSI 102.221 and 101.220. 622ebe860e5cc8c08885787a8fc1eae4c016b092685Ajay Nambi * @param p2 P2 parameter (described in ISO 7816-4). 623a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @return an IccOpenLogicalChannelResponse object. 62457f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal */ 625ebe860e5cc8c08885787a8fc1eae4c016b092685Ajay Nambi IccOpenLogicalChannelResponse iccOpenLogicalChannel(int subId, String AID, int p2); 62657f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal 62757f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal /** 62857f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * Closes a previously opened logical channel to the ICC card. 62957f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * 63057f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * Input parameters equivalent to TS 27.007 AT+CCHC command. 63157f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * 63252103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal * @param subId The subscription to use. 63357f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @param channel is the channel id to be closed as retruned by a 63457f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * successful iccOpenLogicalChannel. 63557f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @return true if the channel was closed successfully. 63657f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal */ 63752103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal boolean iccCloseLogicalChannel(int subId, int channel); 63857f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal 63957f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal /** 64057f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * Transmit an APDU to the ICC card over a logical channel. 64157f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * 64257f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * Input parameters equivalent to TS 27.007 AT+CGLA command. 64357f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * 64452103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal * @param subId The subscription to use. 64557f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @param channel is the channel id to be closed as retruned by a 64657f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * successful iccOpenLogicalChannel. 64757f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @param cla Class of the APDU command. 64857f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @param instruction Instruction of the APDU command. 64957f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @param p1 P1 value of the APDU command. 65057f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @param p2 P2 value of the APDU command. 65157f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @param p3 P3 value of the APDU command. If p3 is negative a 4 byte APDU 65257f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * is sent to the SIM. 65357f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @param data Data to be sent with the APDU. 65457f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal * @return The APDU response from the ICC card with the status appended at 65543d94347a6feb14870a4ffd7682a816210e5e676Shishir Agrawal * the end. 65657f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal */ 65752103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal String iccTransmitApduLogicalChannel(int subId, int channel, int cla, int instruction, 65857f656b9f6271cf857b5ecec5f8c7eacb321ec0bShishir Agrawal int p1, int p2, int p3, String data); 6598f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby 6608f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby /** 661a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * Transmit an APDU to the ICC card over the basic channel. 662a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * 663a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * Input parameters equivalent to TS 27.007 AT+CSIM command. 664a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * 66552103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal * @param subId The subscription to use. 666a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param cla Class of the APDU command. 667a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param instruction Instruction of the APDU command. 668a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param p1 P1 value of the APDU command. 669a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param p2 P2 value of the APDU command. 670a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param p3 P3 value of the APDU command. If p3 is negative a 4 byte APDU 671a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * is sent to the SIM. 672a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param data Data to be sent with the APDU. 673a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @return The APDU response from the ICC card with the status appended at 67443d94347a6feb14870a4ffd7682a816210e5e676Shishir Agrawal * the end. 675a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal */ 67652103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal String iccTransmitApduBasicChannel(int subId, int cla, int instruction, 677a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal int p1, int p2, int p3, String data); 678a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal 679a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal /** 680a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * Returns the response APDU for a command APDU sent through SIM_IO. 681a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * 68252103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal * @param subId The subscription to use. 683a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param fileID 684a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param command 685a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param p1 P1 value of the APDU command. 686a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param p2 P2 value of the APDU command. 687a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param p3 P3 value of the APDU command. 688a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @param filePath 689a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal * @return The APDU response. 690a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal */ 69152103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal byte[] iccExchangeSimIO(int subId, int fileID, int command, int p1, int p2, int p3, 692a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal String filePath); 693a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal 694a122e8df741456ea34e4a57d205411b8371a16dbShishir Agrawal /** 695b8894ab1aec9c9ffa749f9369e412a51b942de27Evan Charlton * Send ENVELOPE to the SIM and returns the response. 696210889e91cb2da74e0323292ca156d17df03fe08Evan Charlton * 69752103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal * @param subId The subscription to use. 698210889e91cb2da74e0323292ca156d17df03fe08Evan Charlton * @param contents String containing SAT/USAT response in hexadecimal 699210889e91cb2da74e0323292ca156d17df03fe08Evan Charlton * format starting with command tag. See TS 102 223 for 700210889e91cb2da74e0323292ca156d17df03fe08Evan Charlton * details. 701b8894ab1aec9c9ffa749f9369e412a51b942de27Evan Charlton * @return The APDU response from the ICC card, with the last 4 bytes 702b8894ab1aec9c9ffa749f9369e412a51b942de27Evan Charlton * being the status word. If the command fails, returns an empty 703b8894ab1aec9c9ffa749f9369e412a51b942de27Evan Charlton * string. 704210889e91cb2da74e0323292ca156d17df03fe08Evan Charlton */ 70552103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal String sendEnvelopeWithStatus(int subId, String content); 706210889e91cb2da74e0323292ca156d17df03fe08Evan Charlton 707210889e91cb2da74e0323292ca156d17df03fe08Evan Charlton /** 7088f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * Read one of the NV items defined in {@link RadioNVItems} / {@code ril_nv_items.h}. 7098f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * Used for device configuration by some CDMA operators. 7108f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * 7118f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * @param itemID the ID of the item to read. 7128f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * @return the NV item as a String, or null on any failure. 7138f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby */ 7148f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby String nvReadItem(int itemID); 7158f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby 7168f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby /** 7178f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * Write one of the NV items defined in {@link RadioNVItems} / {@code ril_nv_items.h}. 7188f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * Used for device configuration by some CDMA operators. 7198f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * 7208f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * @param itemID the ID of the item to read. 7218f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * @param itemValue the value to write, as a String. 7228f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * @return true on success; false on any failure. 7238f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby */ 7248f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby boolean nvWriteItem(int itemID, String itemValue); 7258f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby 7268f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby /** 7278f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * Update the CDMA Preferred Roaming List (PRL) in the radio NV storage. 7288f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * Used for device configuration by some CDMA operators. 7298f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * 7308f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * @param preferredRoamingList byte array containing the new PRL. 7318f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * @return true on success; false on any failure. 7328f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby */ 7338f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby boolean nvWriteCdmaPrl(in byte[] preferredRoamingList); 7348f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby 7358f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby /** 736786e71ab11f2d89afffc9db7473f16206395c813Jake Hamby * Perform the specified type of NV config reset. The radio will be taken offline 737786e71ab11f2d89afffc9db7473f16206395c813Jake Hamby * and the device must be rebooted after the operation. Used for device 738786e71ab11f2d89afffc9db7473f16206395c813Jake Hamby * configuration by some CDMA operators. 7398f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * 7408f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * @param resetType the type of reset to perform (1 == factory reset; 2 == NV-only reset). 7418f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby * @return true on success; false on any failure. 7428f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby */ 7438f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby boolean nvResetConfig(int resetType); 7448f9b33e77686de8e917ba61c5e2f2e31a1e0e49bJake Hamby 7459bbb37116d2c5b597f9b5e3094ff328971e03c0bEvan Charlton /* 7461365703d4964466472904dc84117a0946d9e1a44Junda Liu * Get the calculated preferred network type. 7471365703d4964466472904dc84117a0946d9e1a44Junda Liu * Used for device configuration by some CDMA operators. 74816a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov * @param callingPackage The package making the call. 7491365703d4964466472904dc84117a0946d9e1a44Junda Liu * 7501365703d4964466472904dc84117a0946d9e1a44Junda Liu * @return the calculated preferred network type, defined in RILConstants.java. 7511365703d4964466472904dc84117a0946d9e1a44Junda Liu */ 75216a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov int getCalculatedPreferredNetworkType(String callingPackage); 7531365703d4964466472904dc84117a0946d9e1a44Junda Liu 7541365703d4964466472904dc84117a0946d9e1a44Junda Liu /* 7554a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby * Get the preferred network type. 7564a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby * Used for device configuration by some CDMA operators. 7574a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby * 758984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott * @param subId the id of the subscription to query. 7594a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby * @return the preferred network type, defined in RILConstants.java. 7604a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby */ 761984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott int getPreferredNetworkType(int subId); 7624a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby 7634a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby /** 76438531581fc19f9172fabe56047b326e5dab88625Junda Liu * Check TETHER_DUN_REQUIRED and TETHER_DUN_APN settings, net.tethering.noprovisioning 76538531581fc19f9172fabe56047b326e5dab88625Junda Liu * SystemProperty, and config_tether_apndata to decide whether DUN APN is required for 76638531581fc19f9172fabe56047b326e5dab88625Junda Liu * tethering. 76738531581fc19f9172fabe56047b326e5dab88625Junda Liu * 76838531581fc19f9172fabe56047b326e5dab88625Junda Liu * @return 0: Not required. 1: required. 2: Not set. 76938531581fc19f9172fabe56047b326e5dab88625Junda Liu */ 77038531581fc19f9172fabe56047b326e5dab88625Junda Liu int getTetherApnRequired(); 77138531581fc19f9172fabe56047b326e5dab88625Junda Liu 77238531581fc19f9172fabe56047b326e5dab88625Junda Liu /** 773e37ebbffb01042b667633362459c3a069575ad46Brad Ebinger * Get ImsServiceController binder from ImsResolver that corresponds to the subId and feature 774e37ebbffb01042b667633362459c3a069575ad46Brad Ebinger * requested as well as registering the ImsServiceController for callbacks using the 775e37ebbffb01042b667633362459c3a069575ad46Brad Ebinger * IImsServiceFeatureListener interface. 776e37ebbffb01042b667633362459c3a069575ad46Brad Ebinger */ 7777e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe IImsServiceController getImsServiceControllerAndListen(int slotIndex, int feature, 778e37ebbffb01042b667633362459c3a069575ad46Brad Ebinger IImsServiceFeatureListener callback); 779e37ebbffb01042b667633362459c3a069575ad46Brad Ebinger 780e37ebbffb01042b667633362459c3a069575ad46Brad Ebinger /** 781984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott * Set the network selection mode to automatic. 782984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott * 783984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott * @param subId the id of the subscription to update. 784984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott */ 785984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott void setNetworkSelectionModeAutomatic(int subId); 786984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott 787984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott /** 788d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal * Perform a radio scan and return the list of avialble networks. 789d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal * 790d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal * @param subId the id of the subscription. 791d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal * @return CellNetworkScanResult containing status of scan and networks. 792d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal */ 793d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal CellNetworkScanResult getCellNetworkScanResults(int subId); 794d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal 795d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal /** 796d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal * Ask the radio to connect to the input network and change selection mode to manual. 797d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal * 798d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal * @param subId the id of the subscription. 799d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal * @param operatorInfo the operator to attach to. 800e25bd01ad662d1a5b19592c98fac0a3035081375Shishir Agrawal * @param persistSelection should the selection persist till reboot or its 801e25bd01ad662d1a5b19592c98fac0a3035081375Shishir Agrawal * turned off? Will also result in notification being not shown to 802e25bd01ad662d1a5b19592c98fac0a3035081375Shishir Agrawal * the user if the signal is lost. 803d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal * @return true if the request suceeded. 804d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal */ 805e25bd01ad662d1a5b19592c98fac0a3035081375Shishir Agrawal boolean setNetworkSelectionModeManual(int subId, in OperatorInfo operator, 806e25bd01ad662d1a5b19592c98fac0a3035081375Shishir Agrawal boolean persistSelection); 807d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal 808d4f2bcdab5a43e6439babfd5eefeaff908b73870Shishir Agrawal /** 8094a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby * Set the preferred network type. 8104a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby * Used for device configuration by some CDMA operators. 8114a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby * 812984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott * @param subId the id of the subscription to update. 8134a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby * @param networkType the preferred network type, defined in RILConstants.java. 8144a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby * @return true on success; false on any failure. 8154a2fa35a6ad03d5ee1cd03ae94b4e7d70b50811cJake Hamby */ 816984dc850b4caeb4470e52bce773935be5305cf8eStuart Scott boolean setPreferredNetworkType(int subId, int networkType); 817afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt 818afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt /** 819afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt * User enable/disable Mobile Data. 820afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt * 821afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt * @param enable true to turn on, else false 822afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt */ 82336ffb0494dd1045c164b7479b68165e206f8c759Wink Saville void setDataEnabled(int subId, boolean enable); 824afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt 825afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt /** 826afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt * Get the user enabled state of Mobile Data. 827afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt * 828afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt * @return true on enabled 829afa05c0b43cbc065181d5c2d6ee368a08bb00c3bRobert Greenwalt */ 83036ffb0494dd1045c164b7479b68165e206f8c759Wink Saville boolean getDataEnabled(int subId); 831fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 832fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 833fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Get P-CSCF address from PCO after data connection is established or modified. 834e647099e14114475e9a2827a10dab2d2e36308c4ram * @param apnType the apnType, "ims" for IMS APN, "emergency" for EMERGENCY APN 83516a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov * @param callingPackage The package making the call. 836fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 83716a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov String[] getPcscfAddress(String apnType, String callingPackage); 838fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 839fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville /** 840fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville * Set IMS registration state 841fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville */ 842fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville void setImsRegistrationState(boolean registered); 843fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 844762d5a091f5e19b568bb0ff81a2cb6785b69075fShishir Agrawal /** 8452b2469b07d6ea9410bdb8d1234aa2320b02bdaa9Junda Liu * Return MDN string for CDMA phone. 8462b2469b07d6ea9410bdb8d1234aa2320b02bdaa9Junda Liu * @param subId user preferred subId. 8472b2469b07d6ea9410bdb8d1234aa2320b02bdaa9Junda Liu */ 84863f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville String getCdmaMdn(int subId); 8492b2469b07d6ea9410bdb8d1234aa2320b02bdaa9Junda Liu 8502b2469b07d6ea9410bdb8d1234aa2320b02bdaa9Junda Liu /** 8512b2469b07d6ea9410bdb8d1234aa2320b02bdaa9Junda Liu * Return MIN string for CDMA phone. 8522b2469b07d6ea9410bdb8d1234aa2320b02bdaa9Junda Liu * @param subId user preferred subId. 8532b2469b07d6ea9410bdb8d1234aa2320b02bdaa9Junda Liu */ 85463f03dd94c43c22f2c77306059b5748e5e1e0e3cWink Saville String getCdmaMin(int subId); 8552b2469b07d6ea9410bdb8d1234aa2320b02bdaa9Junda Liu 8562b2469b07d6ea9410bdb8d1234aa2320b02bdaa9Junda Liu /** 857762d5a091f5e19b568bb0ff81a2cb6785b69075fShishir Agrawal * Has the calling application been granted special privileges by the carrier. 858762d5a091f5e19b568bb0ff81a2cb6785b69075fShishir Agrawal * 859762d5a091f5e19b568bb0ff81a2cb6785b69075fShishir Agrawal * If any of the packages in the calling UID has carrier privileges, the 860762d5a091f5e19b568bb0ff81a2cb6785b69075fShishir Agrawal * call will return true. This access is granted by the owner of the UICC 861762d5a091f5e19b568bb0ff81a2cb6785b69075fShishir Agrawal * card and does not depend on the registered carrier. 862762d5a091f5e19b568bb0ff81a2cb6785b69075fShishir Agrawal * 863762d5a091f5e19b568bb0ff81a2cb6785b69075fShishir Agrawal * TODO: Add a link to documentation. 864762d5a091f5e19b568bb0ff81a2cb6785b69075fShishir Agrawal * 86552103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal * @param subId The subscription to use. 866fc3646f58e5851e7a483b8388bdd826078166d10Shishir Agrawal * @return carrier privilege status defined in TelephonyManager. 867762d5a091f5e19b568bb0ff81a2cb6785b69075fShishir Agrawal */ 86852103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal int getCarrierPrivilegeStatus(int subId); 869142529702dad9a6612271f487d500db80173ba7bJunda Liu 870142529702dad9a6612271f487d500db80173ba7bJunda Liu /** 871b4b9ca7580c75f07330e5222cbd9ccc93b12935eZach Johnson * Similar to above, but check for the package whose name is pkgName. 872142529702dad9a6612271f487d500db80173ba7bJunda Liu */ 873b4b9ca7580c75f07330e5222cbd9ccc93b12935eZach Johnson int checkCarrierPrivilegesForPackage(String pkgName); 874b4b9ca7580c75f07330e5222cbd9ccc93b12935eZach Johnson 875b4b9ca7580c75f07330e5222cbd9ccc93b12935eZach Johnson /** 876b4b9ca7580c75f07330e5222cbd9ccc93b12935eZach Johnson * Similar to above, but check across all phones. 877b4b9ca7580c75f07330e5222cbd9ccc93b12935eZach Johnson */ 878b4b9ca7580c75f07330e5222cbd9ccc93b12935eZach Johnson int checkCarrierPrivilegesForPackageAnyPhone(String pkgName); 879f9aefdb534c6cb2af22dfb7614a1c15c2d67dd9cDerek Tan 880f9aefdb534c6cb2af22dfb7614a1c15c2d67dd9cDerek Tan /** 881f3c7bf432dc5c21fdecbb44865c037313d21b4cfJunda Liu * Returns list of the package names of the carrier apps that should handle the input intent 882f3c7bf432dc5c21fdecbb44865c037313d21b4cfJunda Liu * and have carrier privileges for the given phoneId. 88363c4c06be44fe8bd4506e6f9f57361d31e947c21Shishir Agrawal * 8843892fc0349a91097f53152eaf2801dfebb2066caDiego Pontoriero * @param intent Intent that will be sent. 885f3c7bf432dc5c21fdecbb44865c037313d21b4cfJunda Liu * @param phoneId The phoneId on which the carrier app has carrier privileges. 886f3c7bf432dc5c21fdecbb44865c037313d21b4cfJunda Liu * @return list of carrier app package names that can handle the intent on phoneId. 88763c4c06be44fe8bd4506e6f9f57361d31e947c21Shishir Agrawal * Returns null if there is an error and an empty list if there 88863c4c06be44fe8bd4506e6f9f57361d31e947c21Shishir Agrawal * are no matching packages. 88963c4c06be44fe8bd4506e6f9f57361d31e947c21Shishir Agrawal */ 890f3c7bf432dc5c21fdecbb44865c037313d21b4cfJunda Liu List<String> getCarrierPackageNamesForIntentAndPhone(in Intent intent, int phoneId); 89163c4c06be44fe8bd4506e6f9f57361d31e947c21Shishir Agrawal 89263c4c06be44fe8bd4506e6f9f57361d31e947c21Shishir Agrawal /** 8932bae510ccef2da7dd767f8148d4e3539037f4aaaDerek Tan * Set the line 1 phone number string and its alphatag for the current ICCID 8942bae510ccef2da7dd767f8148d4e3539037f4aaaDerek Tan * for display purpose only, for example, displayed in Phone Status. It won't 8952bae510ccef2da7dd767f8148d4e3539037f4aaaDerek Tan * change the actual MSISDN/MDN. To unset alphatag or number, pass in a null 8962bae510ccef2da7dd767f8148d4e3539037f4aaaDerek Tan * value. 897818631b679171ffb49eaa641bee06b9c953651daDerek Tan * 898818631b679171ffb49eaa641bee06b9c953651daDerek Tan * @param subId the subscriber that the alphatag and dialing number belongs to. 899818631b679171ffb49eaa641bee06b9c953651daDerek Tan * @param alphaTag alpha-tagging of the dailing nubmer 900818631b679171ffb49eaa641bee06b9c953651daDerek Tan * @param number The dialing number 9010201a6f6f16a872405a5f9ee65026e948eb162d0Shishir Agrawal * @return true if the operation was executed correctly. 902818631b679171ffb49eaa641bee06b9c953651daDerek Tan */ 9030201a6f6f16a872405a5f9ee65026e948eb162d0Shishir Agrawal boolean setLine1NumberForDisplayForSubscriber(int subId, String alphaTag, String number); 904818631b679171ffb49eaa641bee06b9c953651daDerek Tan 905818631b679171ffb49eaa641bee06b9c953651daDerek Tan /** 906818631b679171ffb49eaa641bee06b9c953651daDerek Tan * Returns the displayed dialing number string if it was set previously via 907818631b679171ffb49eaa641bee06b9c953651daDerek Tan * {@link #setLine1NumberForDisplay}. Otherwise returns null. 908818631b679171ffb49eaa641bee06b9c953651daDerek Tan * 909818631b679171ffb49eaa641bee06b9c953651daDerek Tan * @param subId whose dialing number for line 1 is returned. 91016a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov * @param callingPackage The package making the call. 911818631b679171ffb49eaa641bee06b9c953651daDerek Tan * @return the displayed dialing number if set, or null if not set. 912818631b679171ffb49eaa641bee06b9c953651daDerek Tan */ 91316a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov String getLine1NumberForDisplay(int subId, String callingPackage); 914818631b679171ffb49eaa641bee06b9c953651daDerek Tan 915818631b679171ffb49eaa641bee06b9c953651daDerek Tan /** 916818631b679171ffb49eaa641bee06b9c953651daDerek Tan * Returns the displayed alphatag of the dialing number if it was set 917818631b679171ffb49eaa641bee06b9c953651daDerek Tan * previously via {@link #setLine1NumberForDisplay}. Otherwise returns null. 918818631b679171ffb49eaa641bee06b9c953651daDerek Tan * 919818631b679171ffb49eaa641bee06b9c953651daDerek Tan * @param subId whose alphatag associated with line 1 is returned. 92016a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov * @param callingPackage The package making the call. 921818631b679171ffb49eaa641bee06b9c953651daDerek Tan * @return the displayed alphatag of the dialing number if set, or null if 922818631b679171ffb49eaa641bee06b9c953651daDerek Tan * not set. 923818631b679171ffb49eaa641bee06b9c953651daDerek Tan */ 92416a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov String getLine1AlphaTagForDisplay(int subId, String callingPackage); 92586578cca383562c72751d747905280afdeb2bdfbShishir Agrawal 926d24e4eafdb3e42de5a8fd080fcd50ebf4c7bcb71Fyodor Kupolov String[] getMergedSubscriberIds(String callingPackage); 9273256601f5e4d94713f59e97b9d4912875c1bdcafJeff Sharkey 92886578cca383562c72751d747905280afdeb2bdfbShishir Agrawal /** 929d2cfa92146ecfa5e00d4a3ce8e63b1a588845fe2Shishir Agrawal * Override the operator branding for the current ICCID. 93086578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * 931d2cfa92146ecfa5e00d4a3ce8e63b1a588845fe2Shishir Agrawal * Once set, whenever the SIM is present in the device, the service 93286578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * provider name (SPN) and the operator name will both be replaced by the 93386578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * brand value input. To unset the value, the same function should be 93486578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * called with a null brand value. 93586578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * 93686578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * <p>Requires Permission: 93786578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE} 93886578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * or has to be carrier app - see #hasCarrierPrivileges. 93986578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * 94052103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal * @param subId The subscription to use. 94186578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * @param brand The brand name to display/set. 94286578cca383562c72751d747905280afdeb2bdfbShishir Agrawal * @return true if the operation was executed correctly. 94386578cca383562c72751d747905280afdeb2bdfbShishir Agrawal */ 94452103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal boolean setOperatorBrandOverride(int subId, String brand); 9453099c831441e861328cd4965011c854e060ce56aSteven Liu 9463099c831441e861328cd4965011c854e060ce56aSteven Liu /** 9475fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * Override the roaming indicator for the current ICCID. 9485fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * 9495fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * Using this call, the carrier app (see #hasCarrierPrivileges) can override 9505fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * the platform's notion of a network operator being considered roaming or not. 9515fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * The change only affects the ICCID that was active when this call was made. 9525fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * 9535fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * If null is passed as any of the input, the corresponding value is deleted. 9545fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * 9555fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * <p>Requires that the caller have carrier privilege. See #hasCarrierPrivileges. 9565fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * 95752103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal * @param subId for which the roaming overrides apply. 9585fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * @param gsmRoamingList - List of MCCMNCs to be considered roaming for 3GPP RATs. 9595fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * @param gsmNonRoamingList - List of MCCMNCs to be considered not roaming for 3GPP RATs. 9605fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * @param cdmaRoamingList - List of SIDs to be considered roaming for 3GPP2 RATs. 9615fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * @param cdmaNonRoamingList - List of SIDs to be considered not roaming for 3GPP2 RATs. 9625fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal * @return true if the operation was executed correctly. 9635fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal */ 96452103938915205cfd1febe09e2cae58060a8ef74Shishir Agrawal boolean setRoamingOverride(int subId, in List<String> gsmRoamingList, 9655fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal in List<String> gsmNonRoamingList, in List<String> cdmaRoamingList, 9665fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal in List<String> cdmaNonRoamingList); 9675fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal 9685fb1118d8c8a19bbbf4abc679b55f08cdfb79ba8Shishir Agrawal /** 9693099c831441e861328cd4965011c854e060ce56aSteven Liu * Returns the result and response from RIL for oem request 9703099c831441e861328cd4965011c854e060ce56aSteven Liu * 9713099c831441e861328cd4965011c854e060ce56aSteven Liu * @param oemReq the data is sent to ril. 9723099c831441e861328cd4965011c854e060ce56aSteven Liu * @param oemResp the respose data from RIL. 9733099c831441e861328cd4965011c854e060ce56aSteven Liu * @return negative value request was not handled or get error 9743099c831441e861328cd4965011c854e060ce56aSteven Liu * 0 request was handled succesfully, but no response data 9753099c831441e861328cd4965011c854e060ce56aSteven Liu * positive value success, data length of response 9763099c831441e861328cd4965011c854e060ce56aSteven Liu */ 9773099c831441e861328cd4965011c854e060ce56aSteven Liu int invokeOemRilRequestRaw(in byte[] oemReq, out byte[] oemResp); 978fb40dd4d00bd3361b2535bc866e6c21eadc52558Wink Saville 979bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla /** 980bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla * Check if any mobile Radios need to be shutdown. 981bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla * 982bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla * @return true is any mobile radio needs to be shutdown 983bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla */ 984bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla boolean needMobileRadioShutdown(); 985bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla 986bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla /** 987bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla * Shutdown Mobile Radios 988bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla */ 989bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla void shutdownMobileRadios(); 9902af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville 9912af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville /** 9922af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville * Set phone radio type and access technology. 9932af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville * 9942af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville * @param rafs an RadioAccessFamily array to indicate all phone's 9952af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville * new radio access family. The length of RadioAccessFamily 9962af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville * must equ]]al to phone count. 9972af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville */ 9982af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville void setRadioCapability(in RadioAccessFamily[] rafs); 9992af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville 10002af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville /** 10012af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville * Get phone radio type and access technology. 10022af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville * 10032af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville * @param phoneId which phone you want to get 10046e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt * @param callingPackage the name of the package making the call 10052af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville * @return phone radio type and access technology 10062af2d57d578e0c3a2740628e7c6336b19961cc49Wink Saville */ 10076e4a98f8707f759fa9f47a458683a3627e42b0b6Robert Greenwalt int getRadioAccessFamily(in int phoneId, String callingPackage); 10084a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee 10094a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee /** 10104a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee * Enables or disables video calling. 10114a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee * 10124a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee * @param enable Whether to enable video calling. 10134a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee */ 10144a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee void enableVideoCalling(boolean enable); 10154a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee 10164a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee /** 10174a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee * Whether video calling has been enabled by the user. 10184a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee * 101916a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov * @param callingPackage The package making the call. 102067fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee * @return {@code true} if the user has enabled video calling, {@code false} otherwise. 10214a3084a46d80383c528198a48da5c327d7d08a00Andrew Lee */ 102216a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov boolean isVideoCallingEnabled(String callingPackage); 10230b7f5e81ba06f694df8c8cccaea9e009e3200b4cSanket Padawe 10240303be4a8ac109e52b2581b7c6a94b27c581f84fLibin.Tang@motorola.com /** 102567fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee * Whether the DTMF tone length can be changed. 102667fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee * 102767fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee * @return {@code true} if the DTMF tone length can be changed. 102867fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee */ 102967fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee boolean canChangeDtmfToneLength(); 103067fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee 103167fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee /** 103267fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee * Whether the device is a world phone. 103367fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee * 103467fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee * @return {@code true} if the devices is a world phone. 103567fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee */ 103667fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee boolean isWorldPhone(); 103767fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee 103867fc92bd444e4d8eee0aa7703980aff9185ea1bdAndrew Lee /** 1039f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee * Whether the phone supports TTY mode. 1040f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee * 1041f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee * @return {@code true} if the device supports TTY mode. 1042f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee */ 1043f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee boolean isTtyModeSupported(); 1044f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee 1045f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee /** 1046f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee * Whether the phone supports hearing aid compatibility. 1047f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee * 1048f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee * @return {@code true} if the device supports hearing aid compatibility. 1049f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee */ 1050f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee boolean isHearingAidCompatibilitySupported(); 1051b304fc0aafe067e422ce219ba5edb4bc7a68924cEtan Cohen 1052f3c10020e2b76f20adb90d250ab4ed4e20e348d2Andrew Lee /** 10530303be4a8ac109e52b2581b7c6a94b27c581f84fLibin.Tang@motorola.com * Get IMS Registration Status 10540303be4a8ac109e52b2581b7c6a94b27c581f84fLibin.Tang@motorola.com */ 10550303be4a8ac109e52b2581b7c6a94b27c581f84fLibin.Tang@motorola.com boolean isImsRegistered(); 10560b7f5e81ba06f694df8c8cccaea9e009e3200b4cSanket Padawe 10570b7f5e81ba06f694df8c8cccaea9e009e3200b4cSanket Padawe /** 105842eadcdf3432e9fd6662ee07316db7726c1eabbfNathan Harold * Returns the Status of Wi-Fi Calling 105942eadcdf3432e9fd6662ee07316db7726c1eabbfNathan Harold */ 1060b304fc0aafe067e422ce219ba5edb4bc7a68924cEtan Cohen boolean isWifiCallingAvailable(); 1061740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen 1062b304fc0aafe067e422ce219ba5edb4bc7a68924cEtan Cohen /** 1063b304fc0aafe067e422ce219ba5edb4bc7a68924cEtan Cohen * Returns the Status of Volte 1064b304fc0aafe067e422ce219ba5edb4bc7a68924cEtan Cohen */ 1065b304fc0aafe067e422ce219ba5edb4bc7a68924cEtan Cohen boolean isVolteAvailable(); 106642eadcdf3432e9fd6662ee07316db7726c1eabbfNathan Harold 106742eadcdf3432e9fd6662ee07316db7726c1eabbfNathan Harold /** 1068b304fc0aafe067e422ce219ba5edb4bc7a68924cEtan Cohen * Returns the Status of VT (video telephony) 106942eadcdf3432e9fd6662ee07316db7726c1eabbfNathan Harold */ 1070b304fc0aafe067e422ce219ba5edb4bc7a68924cEtan Cohen boolean isVideoTelephonyAvailable(); 107142eadcdf3432e9fd6662ee07316db7726c1eabbfNathan Harold 107242eadcdf3432e9fd6662ee07316db7726c1eabbfNathan Harold /** 10730b7f5e81ba06f694df8c8cccaea9e009e3200b4cSanket Padawe * Returns the unique device ID of phone, for example, the IMEI for 10740b7f5e81ba06f694df8c8cccaea9e009e3200b4cSanket Padawe * GSM and the MEID for CDMA phones. Return null if device ID is not available. 10750b7f5e81ba06f694df8c8cccaea9e009e3200b4cSanket Padawe * 107616a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov * @param callingPackage The package making the call. 10770b7f5e81ba06f694df8c8cccaea9e009e3200b4cSanket Padawe * <p>Requires Permission: 10780b7f5e81ba06f694df8c8cccaea9e009e3200b4cSanket Padawe * {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE} 10790b7f5e81ba06f694df8c8cccaea9e009e3200b4cSanket Padawe */ 108016a16899505ec0a9ede5b76650bfb8817b3227c7Svet Ganov String getDeviceId(String callingPackage); 1081ed4ca5ca2c40ed2c838aaf483fcd58abdfa0ff08Santos Cordon 1082ed4ca5ca2c40ed2c838aaf483fcd58abdfa0ff08Santos Cordon /** 1083dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * Returns the IMEI for the given slot. 1084dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * 10857e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe * @param slotIndex - device slot. 1086dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * @param callingPackage The package making the call. 1087dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * <p>Requires Permission: 1088dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE} 1089dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal */ 10907e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe String getImeiForSlot(int slotIndex, String callingPackage); 1091dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal 1092dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal /** 10930dc3b9104b0e3d9a86cc786acefa45475acfae16Jack Yu * Returns the MEID for the given slot. 10940dc3b9104b0e3d9a86cc786acefa45475acfae16Jack Yu * 10950dc3b9104b0e3d9a86cc786acefa45475acfae16Jack Yu * @param slotIndex - device slot. 10960dc3b9104b0e3d9a86cc786acefa45475acfae16Jack Yu * @param callingPackage The package making the call. 10970dc3b9104b0e3d9a86cc786acefa45475acfae16Jack Yu * <p>Requires Permission: 10980dc3b9104b0e3d9a86cc786acefa45475acfae16Jack Yu * {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE} 10990dc3b9104b0e3d9a86cc786acefa45475acfae16Jack Yu */ 11000dc3b9104b0e3d9a86cc786acefa45475acfae16Jack Yu String getMeidForSlot(int slotIndex, String callingPackage); 11010dc3b9104b0e3d9a86cc786acefa45475acfae16Jack Yu 11020dc3b9104b0e3d9a86cc786acefa45475acfae16Jack Yu /** 1103dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * Returns the device software version. 1104dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * 11057e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe * @param slotIndex - device slot. 1106dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * @param callingPackage The package making the call. 1107dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * <p>Requires Permission: 1108dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal * {@link android.Manifest.permission#READ_PHONE_STATE READ_PHONE_STATE} 1109dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal */ 11107e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe String getDeviceSoftwareVersionForSlot(int slotIndex, String callingPackage); 1111dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal 1112dc50a87495c23068b4150a0fc197e51ace2ae47bShishir Agrawal /** 1113ed4ca5ca2c40ed2c838aaf483fcd58abdfa0ff08Santos Cordon * Returns the subscription ID associated with the specified PhoneAccount. 1114ed4ca5ca2c40ed2c838aaf483fcd58abdfa0ff08Santos Cordon */ 1115ed4ca5ca2c40ed2c838aaf483fcd58abdfa0ff08Santos Cordon int getSubIdForPhoneAccount(in PhoneAccount phoneAccount); 1116f1fb39763d87dabe254b6ed64ac8f20145035bc0Stuart Scott 1117f1fb39763d87dabe254b6ed64ac8f20145035bc0Stuart Scott void factoryReset(int subId); 11187ff76d637f5ad49838e9d4a1570c762a187ed4d1Narayan Kamath 11197ff76d637f5ad49838e9d4a1570c762a187ed4d1Narayan Kamath /** 11207ff76d637f5ad49838e9d4a1570c762a187ed4d1Narayan Kamath * An estimate of the users's current locale based on the default SIM. 11217ff76d637f5ad49838e9d4a1570c762a187ed4d1Narayan Kamath * 11227ff76d637f5ad49838e9d4a1570c762a187ed4d1Narayan Kamath * The returned string will be a well formed BCP-47 language tag, or {@code null} 11237ff76d637f5ad49838e9d4a1570c762a187ed4d1Narayan Kamath * if no locale could be derived. 11247ff76d637f5ad49838e9d4a1570c762a187ed4d1Narayan Kamath */ 11257ff76d637f5ad49838e9d4a1570c762a187ed4d1Narayan Kamath String getLocaleFromDefaultSim(); 11265c728994311c40821604c6711171e860776659a6Prerepa Viswanadham 11275c728994311c40821604c6711171e860776659a6Prerepa Viswanadham /** 1128010bf374d8145528f8733dfa6ef101b15de23a8dAdam Lesinski * Requests the modem activity info asynchronously. 1129010bf374d8145528f8733dfa6ef101b15de23a8dAdam Lesinski * The implementor is expected to reply with the 1130010bf374d8145528f8733dfa6ef101b15de23a8dAdam Lesinski * {@link android.telephony.ModemActivityInfo} object placed into the Bundle with the key 1131010bf374d8145528f8733dfa6ef101b15de23a8dAdam Lesinski * {@link android.telephony.TelephonyManager#MODEM_ACTIVITY_RESULT_KEY}. 1132010bf374d8145528f8733dfa6ef101b15de23a8dAdam Lesinski * The result code is ignored. 11335c728994311c40821604c6711171e860776659a6Prerepa Viswanadham */ 1134010bf374d8145528f8733dfa6ef101b15de23a8dAdam Lesinski oneway void requestModemActivityInfo(in ResultReceiver result); 113539daf8d6f14a01d2854352fe08d14195f7a2056bJack Yu 113639daf8d6f14a01d2854352fe08d14195f7a2056bJack Yu /** 113739daf8d6f14a01d2854352fe08d14195f7a2056bJack Yu * Get the service state on specified subscription 113839daf8d6f14a01d2854352fe08d14195f7a2056bJack Yu * @param subId Subscription id 113939daf8d6f14a01d2854352fe08d14195f7a2056bJack Yu * @param callingPackage The package making the call 114039daf8d6f14a01d2854352fe08d14195f7a2056bJack Yu * @return Service state on specified subscription. 114139daf8d6f14a01d2854352fe08d14195f7a2056bJack Yu */ 114239daf8d6f14a01d2854352fe08d14195f7a2056bJack Yu ServiceState getServiceStateForSubscriber(int subId, String callingPackage); 1143740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen 1144740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen /** 1145740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * Returns the URI for the per-account voicemail ringtone set in Phone settings. 1146740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * 1147740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * @param accountHandle The handle for the {@link PhoneAccount} for which to retrieve the 1148740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * voicemail ringtone. 1149740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * @return The URI for the ringtone to play when receiving a voicemail from a specific 1150740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * PhoneAccount. 1151740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen */ 1152740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen Uri getVoicemailRingtoneUri(in PhoneAccountHandle accountHandle); 1153740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen 1154740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen /** 11552d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * Sets the per-account voicemail ringtone. 11562d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * 11572d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * <p>Requires that the calling app is the default dialer, or has carrier privileges, or 11582d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * has permission {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}. 11592d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * 11602d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * @param phoneAccountHandle The handle for the {@link PhoneAccount} for which to set the 11612d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * voicemail ringtone. 11622d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * @param uri The URI for the ringtone to play when receiving a voicemail from a specific 11632d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * PhoneAccount. 11642d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen */ 11652d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen void setVoicemailRingtoneUri(String callingPackage, 11662d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen in PhoneAccountHandle phoneAccountHandle, in Uri uri); 11672d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen 11682d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen /** 1169740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * Returns whether vibration is set for voicemail notification in Phone settings. 1170740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * 1171740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * @param accountHandle The handle for the {@link PhoneAccount} for which to retrieve the 1172740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * voicemail vibration setting. 1173740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen * @return {@code true} if the vibration is set for this PhoneAccount, {@code false} otherwise. 1174740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen */ 1175740fb3bcca1366e20783dd7656d3ffe6ea3a744eNancy Chen boolean isVoicemailVibrationEnabled(in PhoneAccountHandle accountHandle); 11764ec6368f13a53906757283d50a17ed3ed43eccc4Amith Yamasani 11774ec6368f13a53906757283d50a17ed3ed43eccc4Amith Yamasani /** 11782d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * Sets the per-account preference whether vibration is enabled for voicemail notifications. 11792d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * 11802d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * <p>Requires that the calling app is the default dialer, or has carrier privileges, or 11812d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * has permission {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE}. 11822d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * 11832d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * @param phoneAccountHandle The handle for the {@link PhoneAccount} for which to set the 11842d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * voicemail vibration setting. 11852d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * @param enabled Whether to enable or disable vibration for voicemail notifications from a 11862d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen * specific PhoneAccount. 11872d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen */ 11882d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen void setVoicemailVibrationEnabled(String callingPackage, 11892d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen in PhoneAccountHandle phoneAccountHandle, boolean enabled); 11902d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen 11912d7212d82220765bf998712ef110c5ddef99e3b8Ta-wei Yen /** 11924ec6368f13a53906757283d50a17ed3ed43eccc4Amith Yamasani * Returns a list of packages that have carrier privileges. 11934ec6368f13a53906757283d50a17ed3ed43eccc4Amith Yamasani */ 11944ec6368f13a53906757283d50a17ed3ed43eccc4Amith Yamasani List<String> getPackagesWithCarrierPrivileges(); 11952da9b2b8bfb01744d53c14a65a80035d3c8d7b2fYouhan Wang 11962da9b2b8bfb01744d53c14a65a80035d3c8d7b2fYouhan Wang /** 11972da9b2b8bfb01744d53c14a65a80035d3c8d7b2fYouhan Wang * Return the application ID for the app type. 11982da9b2b8bfb01744d53c14a65a80035d3c8d7b2fYouhan Wang * 11992da9b2b8bfb01744d53c14a65a80035d3c8d7b2fYouhan Wang * @param subId the subscription ID that this request applies to. 12002da9b2b8bfb01744d53c14a65a80035d3c8d7b2fYouhan Wang * @param appType the uicc app type, 12012da9b2b8bfb01744d53c14a65a80035d3c8d7b2fYouhan Wang * @return Application ID for specificied app type or null if no uicc or error. 12022da9b2b8bfb01744d53c14a65a80035d3c8d7b2fYouhan Wang */ 12032da9b2b8bfb01744d53c14a65a80035d3c8d7b2fYouhan Wang String getAidForAppType(int subId, int appType); 12047717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang 12057717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang /** 12067717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang * Return the Electronic Serial Number. 12077717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang * 12087717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang * Requires that the calling app has READ_PRIVILEGED_PHONE_STATE permission 12097717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang * 12107717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang * @param subId the subscription ID that this request applies to. 12117717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang * @return ESN or null if error. 12127717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang * @hide 12137717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang */ 12147717acd174795936756226a4bc367fdcb7b49c5dYouhan Wang String getEsn(int subId); 121506e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padawe 121606e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padawe /** 12174eb5678ed8a0704fe1e4f5e7a3a3156f69b6884fYouhan Wang * Return the Preferred Roaming List Version 12184eb5678ed8a0704fe1e4f5e7a3a3156f69b6884fYouhan Wang * 12194eb5678ed8a0704fe1e4f5e7a3a3156f69b6884fYouhan Wang * Requires that the calling app has READ_PRIVILEGED_PHONE_STATE permission 12204eb5678ed8a0704fe1e4f5e7a3a3156f69b6884fYouhan Wang * @param subId the subscription ID that this request applies to. 12214eb5678ed8a0704fe1e4f5e7a3a3156f69b6884fYouhan Wang * @return PRLVersion or null if error. 12224eb5678ed8a0704fe1e4f5e7a3a3156f69b6884fYouhan Wang * @hide 12234eb5678ed8a0704fe1e4f5e7a3a3156f69b6884fYouhan Wang */ 12244eb5678ed8a0704fe1e4f5e7a3a3156f69b6884fYouhan Wang String getCdmaPrlVersion(int subId); 12254eb5678ed8a0704fe1e4f5e7a3a3156f69b6884fYouhan Wang 12264eb5678ed8a0704fe1e4f5e7a3a3156f69b6884fYouhan Wang /** 122706e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padawe * Get snapshot of Telephony histograms 122806e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padawe * @return List of Telephony histograms 122906e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padawe * Requires Permission: 123006e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padawe * {@link android.Manifest.permission#MODIFY_PHONE_STATE MODIFY_PHONE_STATE} 123106e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padawe * Or the calling app has carrier privileges. 123206e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padawe */ 123306e1ae1a51b9fb8c65e610c22f86380c60a803a0Sanket Padawe List<TelephonyHistogram> getTelephonyHistograms(); 123464997623bfa04e80064b6056fab0fb23144acb44Meng Wang 123564997623bfa04e80064b6056fab0fb23144acb44Meng Wang /** 12367e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe * Set the allowed carrier list for slotIndex 123764997623bfa04e80064b6056fab0fb23144acb44Meng Wang * Require system privileges. In the future we may add this to carrier APIs. 123864997623bfa04e80064b6056fab0fb23144acb44Meng Wang * 123964997623bfa04e80064b6056fab0fb23144acb44Meng Wang * @return The number of carriers set successfully. Should match length of 124064997623bfa04e80064b6056fab0fb23144acb44Meng Wang * carriers on success. 124164997623bfa04e80064b6056fab0fb23144acb44Meng Wang */ 12427e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe int setAllowedCarriers(int slotIndex, in List<CarrierIdentifier> carriers); 124364997623bfa04e80064b6056fab0fb23144acb44Meng Wang 124464997623bfa04e80064b6056fab0fb23144acb44Meng Wang /** 12457e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe * Get the allowed carrier list for slotIndex. 124664997623bfa04e80064b6056fab0fb23144acb44Meng Wang * Require system privileges. In the future we may add this to carrier APIs. 124764997623bfa04e80064b6056fab0fb23144acb44Meng Wang * 124864997623bfa04e80064b6056fab0fb23144acb44Meng Wang * @return List of {@link android.service.carrier.CarrierIdentifier}; empty list 124964997623bfa04e80064b6056fab0fb23144acb44Meng Wang * means all carriers are allowed. 125064997623bfa04e80064b6056fab0fb23144acb44Meng Wang */ 12517e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe List<CarrierIdentifier> getAllowedCarriers(int slotIndex); 12521bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu 1253b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu /** 1254b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu * Action set from carrier signalling broadcast receivers to enable/disable metered apns 1255b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu * Permissions android.Manifest.permission.MODIFY_PHONE_STATE is required 1256b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu * @param subId the subscription ID that this action applies to. 1257b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu * @param enabled control enable or disable metered apns. 1258b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu * @hide 1259b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu */ 12601bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu void carrierActionSetMeteredApnsEnabled(int subId, boolean visible); 12611bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu 12621bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu /** 12631bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu * Action set from carrier signalling broadcast receivers to enable/disable radio 12641bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu * Permissions android.Manifest.permission.MODIFY_PHONE_STATE is required 12651bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu * @param subId the subscription ID that this action applies to. 12661bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu * @param enabled control enable or disable radio. 12671bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu * @hide 12681bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu */ 12691bf6ec2f868041ba4c3d4c88d3ac482bfd4c52b9fionaxu void carrierActionSetRadioEnabled(int subId, boolean enabled); 1270b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu 1271b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu /** 1272b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu * Get aggregated video call data usage since boot. 1273b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu * Permissions android.Manifest.permission.READ_NETWORK_USAGE_HISTORY is required. 1274b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu * @return total data usage in bytes 1275b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu * @hide 1276b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu */ 1277b6587eac06c00c964b6f541e18d307df8c4a9a50Jack Yu long getVtDataUsage(); 12788781b68e2bd6c0080e9c91544557b64783e7dffaJack Yu 12798781b68e2bd6c0080e9c91544557b64783e7dffaJack Yu /** 12808781b68e2bd6c0080e9c91544557b64783e7dffaJack Yu * Policy control of data connection. Usually used when data limit is passed. 12818781b68e2bd6c0080e9c91544557b64783e7dffaJack Yu * @param enabled True if enabling the data, otherwise disabling. 12828781b68e2bd6c0080e9c91544557b64783e7dffaJack Yu * @param subId Subscription index 12838781b68e2bd6c0080e9c91544557b64783e7dffaJack Yu * @hide 12848781b68e2bd6c0080e9c91544557b64783e7dffaJack Yu */ 12858781b68e2bd6c0080e9c91544557b64783e7dffaJack Yu void setPolicyDataEnabled(boolean enabled, int subId); 12868347c3898dfca9db048aa0feb0e52a6b55a205efSooraj Sasindran 12878347c3898dfca9db048aa0feb0e52a6b55a205efSooraj Sasindran /** 12888347c3898dfca9db048aa0feb0e52a6b55a205efSooraj Sasindran * Get Client request stats which will contain statistical information 12898347c3898dfca9db048aa0feb0e52a6b55a205efSooraj Sasindran * on each request made by client. 12908347c3898dfca9db048aa0feb0e52a6b55a205efSooraj Sasindran * @param callingPackage package making the call. 12918347c3898dfca9db048aa0feb0e52a6b55a205efSooraj Sasindran * @param subId Subscription index 12928347c3898dfca9db048aa0feb0e52a6b55a205efSooraj Sasindran * @hide 12938347c3898dfca9db048aa0feb0e52a6b55a205efSooraj Sasindran */ 12948347c3898dfca9db048aa0feb0e52a6b55a205efSooraj Sasindran List<ClientRequestStats> getClientRequestStats(String callingPackage, int subid); 12956078cfebb074bbd0db504182d12e2774f1000bffJack Yu 12966078cfebb074bbd0db504182d12e2774f1000bffJack Yu /** 12976078cfebb074bbd0db504182d12e2774f1000bffJack Yu * Set SIM card power state. Request is equivalent to inserting or removing the card. 12987e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe * @param slotIndex SIM slot id 12996078cfebb074bbd0db504182d12e2774f1000bffJack Yu * @param powerUp True if powering up the SIM, otherwise powering down 13006078cfebb074bbd0db504182d12e2774f1000bffJack Yu * @hide 13016078cfebb074bbd0db504182d12e2774f1000bffJack Yu * */ 13027e4602519977b6bb9c41afc91a44ca782e716e40Sanket Padawe void setSimPowerStateForSlot(int slotIndex, boolean powerUp); 1303f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold 13046a7c9333b92a1c7807a02eeffc1b10041af3d70eNathan Harold /** 1305f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold * Returns a list of Forbidden PLMNs from the specified SIM App 1306f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold * Returns null if the query fails. 1307f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold * 1308f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold * 1309f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold * <p>Requires that the calling app has READ_PRIVILEGED_PHONE_STATE 1310f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold * 1311f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold * @param subId subscription ID used for authentication 1312f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold * @param appType the icc application type, like {@link #APPTYPE_USIM} 1313f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold */ 1314f56cd7073403ebc63d97ee1f6ade1c74e7f1ccaaNathan Harold String[] getForbiddenPlmns(int subId, int appType); 1315cfe9e61ce4029da61b973f5b80fccafdde4c9cc3Shuo Qian 1316cfe9e61ce4029da61b973f5b80fccafdde4c9cc3Shuo Qian /** 1317cfe9e61ce4029da61b973f5b80fccafdde4c9cc3Shuo Qian * Check if phone is in emergency callback mode 1318cfe9e61ce4029da61b973f5b80fccafdde4c9cc3Shuo Qian * @return true if phone is in emergency callback mode 1319cfe9e61ce4029da61b973f5b80fccafdde4c9cc3Shuo Qian * @param subId the subscription ID that this action applies to. 1320cfe9e61ce4029da61b973f5b80fccafdde4c9cc3Shuo Qian * @hide 1321cfe9e61ce4029da61b973f5b80fccafdde4c9cc3Shuo Qian */ 1322cfe9e61ce4029da61b973f5b80fccafdde4c9cc3Shuo Qian boolean getEmergencyCallbackMode(int subId); 1323bd7723637b14d1895c043c2257f1cd9560322d4eNaveen Kalla} 1324