return false;
}
+ /*
+ * Obtain the current state of Wi-Fi calling.
+ *
+ * @hide
+ * @see android.telephony.TelephonyManager.WifiCallingChoices
+ */
+ public int getWhenToMakeWifiCalls() {
+ try {
+ return getITelephony().getWhenToMakeWifiCalls();
+ } catch (RemoteException ex) {
+ return WifiCallingChoices.NEVER_USE;
+ }
+ }
+
+ /**
+ * Set the current state of Wi-Fi calling.
+ *
+ * @hide
+ * @see android.telephony.TelephonyManager.WifiCallingChoices
+ */
+ public void setWhenToMakeWifiCalls(int state) {
+ try {
+ getITelephony().setWhenToMakeWifiCalls(state);
+ } catch (RemoteException ex) {
+ }
+ }
++
+ /**
+ * Get the preferred network type.
+ * Used for device configuration by some CDMA operators.
+ *
+ * @return the preferred network type, defined in RILConstants.java.
+ * @hide
+ */
+ public int getPreferredNetworkType() {
+ try {
+ return getITelephony().getPreferredNetworkType();
+ } catch (RemoteException ex) {
+ Rlog.e(TAG, "getPreferredNetworkType RemoteException", ex);
+ } catch (NullPointerException ex) {
+ Rlog.e(TAG, "getPreferredNetworkType NPE", ex);
+ }
+ return -1;
+ }
+
+ /**
+ * Set the preferred network type.
+ * Used for device configuration by some CDMA operators.
+ *
+ * @param networkType the preferred network type, defined in RILConstants.java.
+ * @return true on success; false on any failure.
+ * @hide
+ */
+ public boolean setPreferredNetworkType(int networkType) {
+ try {
+ return getITelephony().setPreferredNetworkType(networkType);
+ } catch (RemoteException ex) {
+ Rlog.e(TAG, "setPreferredNetworkType RemoteException", ex);
+ } catch (NullPointerException ex) {
+ Rlog.e(TAG, "setPreferredNetworkType NPE", ex);
+ }
+ return false;
+ }
}
boolean nvResetConfig(int resetType);
/**
+ * Inform the phone about a new incoming third party call. The phone will bind to the service
+ * identified by component to handle the call.
+ * @param component the component that should handle the intent.
+ * @param callId the unique id of the call.
+ * @param callerDisplayName the name shown to the user. Normally this will be the caller's phone
+ * number.
+ */
+ void newIncomingThirdPartyCall(in ComponentName component, String callId,
+ String callerDisplayName);
+
+ /**
+ * Obtain the current state of Wi-Fi calling.
+ *
+ * @see android.telephony.TelephonyManager.WifiCallingChoices
+ */
+ int getWhenToMakeWifiCalls();
+
+ /**
+ * Set the current state of Wi-Fi calling.
+ *
+ * @see android.telephony.TelephonyManager.WifiCallingChoices
+ */
+ void setWhenToMakeWifiCalls(int state);
++
++ /*
+ * Get the preferred network type.
+ * Used for device configuration by some CDMA operators.
+ *
+ * @return the preferred network type, defined in RILConstants.java.
+ */
+ int getPreferredNetworkType();
+
+ /**
+ * Set the preferred network type.
+ * Used for device configuration by some CDMA operators.
+ *
+ * @param networkType the preferred network type, defined in RILConstants.java.
+ * @return true on success; false on any failure.
+ */
+ boolean setPreferredNetworkType(int networkType);
}