Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f591fe09 authored by Arc Wang's avatar Arc Wang
Browse files

[Wi-Fi] Remove passpoint methods in WifiEntryShell


Bug: 143326832
Test: build
Change-Id: I9d21909f18df03d50f69447c3f2014b75ecd2d8b
parent 4ee5d181
Loading
Loading
Loading
Loading
+0 −38
Original line number Diff line number Diff line
@@ -23,7 +23,6 @@ import com.android.wifitrackerlib.WifiEntry;
 * all the unavalable {@link AccessPoint} methods & constants.
 *
 * TODO(b/143326832): Replace all methods & constants with WifiEntry version when it's available.
 * TODO(b/143326832): How about AccessPoint#getSettingsSummary(boolean convertSavedAsDisconnected)?
 */
public class WifiEntryShell {
    public WifiEntryShell(){};
@@ -47,41 +46,4 @@ public class WifiEntryShell {
     * Upper bound on the 5.0 GHz (802.11a/h/j/n/ac) WLAN channels
     */
    public static final int HIGHER_FREQ_5GHZ = 5900;

    // Passpoint methods

    /**
     * Mapping of the corresponding {@link AccessPoint} method
     */
    public static boolean isExpired(WifiEntry wifiEntry) {
        return false;
    }

    /**
     * Mapping of the corresponding {@link AccessPoint} method
     */
    public static boolean isPasspointConfigurationR1(WifiEntry wifiEntry) {
        return false;
    }

    /**
     * Mapping of the corresponding {@link AccessPoint} method
     */
    public static boolean isPasspointConfigurationOsuProvisioned(WifiEntry wifiEntry) {
        return false;
    }

    /**
     * Mapping of the corresponding {@link AccessPoint} method
     */
    public static boolean isOsuProvider(WifiEntry wifiEntry) {
        return false;
    }

    /**
     * Mapping of the corresponding {@link AccessPoint} method
     */
    public static String getPasspointFqdn(WifiEntry wifiEntry) {
        return "Fake passpoint FQDN";
    }
}
+2 −3
Original line number Diff line number Diff line
@@ -537,7 +537,7 @@ public class WifiDetailPreferenceController2 extends AbstractPreferenceControlle
    }

    private void refreshSsid() {
        if (mWifiEntry.isSubscription() || WifiEntryShell.isOsuProvider(mWifiEntry)) {
        if (mWifiEntry.isSubscription()) {
            mSsidPref.setVisible(true);
            mSsidPref.setSummary(mWifiEntry.getTitle());
        } else {
@@ -743,8 +743,7 @@ public class WifiDetailPreferenceController2 extends AbstractPreferenceControlle
                    try {
                        mWifiEntry.forget(this);
                    } catch (RuntimeException e) {
                        Log.e(TAG, "Failed to remove Passpoint configuration for "
                                + WifiEntryShell.getPasspointFqdn(mWifiEntry));
                        Log.e(TAG, "Failed to remove Passpoint configuration: " + e);
                    }
                    mMetricsFeatureProvider.action(
                            mFragment.getActivity(), SettingsEnums.ACTION_WIFI_FORGET);