use of android.telephony.VoLteServiceState in project android_frameworks_base by crdroidandroid.
the class TelephonyRegistry method notifyVoLteServiceStateChanged.
public void notifyVoLteServiceStateChanged(VoLteServiceState lteState) {
if (!checkNotifyPermission("notifyVoLteServiceStateChanged()")) {
return;
}
synchronized (mRecords) {
mVoLteServiceState = lteState;
for (Record r : mRecords) {
if (r.matchPhoneStateListenerEvent(PhoneStateListener.LISTEN_VOLTE_STATE)) {
try {
r.callback.onVoLteServiceStateChanged(new VoLteServiceState(mVoLteServiceState));
} catch (RemoteException ex) {
mRemoveList.add(r.binder);
}
}
}
handleRemoveListLocked();
}
}
use of android.telephony.VoLteServiceState in project android_frameworks_opt_telephony by LineageOS.
the class DefaultPhoneNotifierTest method testNotifyVoLteServiceStateChanged.
@Test
@SmallTest
public void testNotifyVoLteServiceStateChanged() throws Exception {
VoLteServiceState state = new VoLteServiceState(VoLteServiceState.NOT_SUPPORTED);
mDefaultPhoneNotifierUT.notifyVoLteServiceStateChanged(mPhone, state);
verify(mTelephonyRegisteryMock).notifyVoLteServiceStateChanged(state);
state = new VoLteServiceState(VoLteServiceState.HANDOVER_COMPLETED);
mDefaultPhoneNotifierUT.notifyVoLteServiceStateChanged(mPhone, state);
verify(mTelephonyRegisteryMock).notifyVoLteServiceStateChanged(state);
}
use of android.telephony.VoLteServiceState in project android_frameworks_opt_telephony by LineageOS.
the class VoLteServiceStateTest method testCopy.
@SmallTest
public void testCopy() {
VoLteServiceState state = new VoLteServiceState(VoLteServiceState.HANDOVER_STARTED);
VoLteServiceState newState = new VoLteServiceState(state);
assertEquals(state, newState);
}
use of android.telephony.VoLteServiceState in project android_frameworks_opt_telephony by LineageOS.
the class VoLteServiceStateTest method testParcel.
@SmallTest
public void testParcel() {
VoLteServiceState state = new VoLteServiceState(VoLteServiceState.HANDOVER_FAILED);
Parcel p = Parcel.obtain();
state.writeToParcel(p, 0);
p.setDataPosition(0);
VoLteServiceState newState = VoLteServiceState.CREATOR.createFromParcel(p);
assertEquals(state, newState);
}
use of android.telephony.VoLteServiceState in project android_frameworks_opt_telephony by LineageOS.
the class VoLteServiceStateTest method testGetState.
@SmallTest
public void testGetState() {
VoLteServiceState state = new VoLteServiceState(VoLteServiceState.HANDOVER_STARTED);
assertEquals(VoLteServiceState.HANDOVER_STARTED, state.getSrvccState());
}
Aggregations