use of com.android.ims.ImsCallForwardInfo in project android_frameworks_opt_telephony by LineageOS.
the class ImsPhone method handleCfQueryResult.
private CallForwardInfo[] handleCfQueryResult(ImsCallForwardInfo[] infos) {
CallForwardInfo[] cfInfos = null;
if (infos != null && infos.length != 0) {
cfInfos = new CallForwardInfo[infos.length];
}
IccRecords r = mDefaultPhone.getIccRecords();
if (infos == null || infos.length == 0) {
if (r != null) {
// Assume the default is not active
// Set unconditional CFF in SIM to false
setVoiceCallForwardingFlag(r, 1, false, null);
}
} else {
for (int i = 0, s = infos.length; i < s; i++) {
if (infos[i].mCondition == ImsUtInterface.CDIV_CF_UNCONDITIONAL) {
if (r != null) {
setVoiceCallForwardingFlag(r, 1, (infos[i].mStatus == 1), infos[i].mNumber);
}
}
cfInfos[i] = getCallForwardInfo(infos[i]);
}
}
return cfInfos;
}
Aggregations