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

Commit 2cd3086c authored by Sarah Chin's avatar Sarah Chin
Browse files

Remove unnecessary frequency range compare API

Compare ranges directly

Test: atest NetworkTypeControllerTest
Bug: 233048459
Change-Id: Iad85437bb0d289f4f3c44e1a0642c780d55edcdb
parent 39dfa886
Loading
Loading
Loading
Loading
+0 −16
Original line number Diff line number Diff line
@@ -138,13 +138,6 @@ public class ServiceState implements Parcelable {
     */
    public static final int FREQUENCY_RANGE_MMWAVE = 4;

    private static final List<Integer> FREQUENCY_RANGE_ORDER = Arrays.asList(
            FREQUENCY_RANGE_UNKNOWN,
            FREQUENCY_RANGE_LOW,
            FREQUENCY_RANGE_MID,
            FREQUENCY_RANGE_HIGH,
            FREQUENCY_RANGE_MMWAVE);

    /** @hide */
    @Retention(RetentionPolicy.SOURCE)
    @IntDef(prefix = "DUPLEX_MODE_",
@@ -2107,15 +2100,6 @@ public class ServiceState implements Parcelable {
        }
    }

    /**
     * @hide
     */
    public static final int getBetterNRFrequencyRange(int range1, int range2) {
        return FREQUENCY_RANGE_ORDER.indexOf(range1) > FREQUENCY_RANGE_ORDER.indexOf(range2)
                ? range1
                : range2;
    }

    /**
     * Returns a copy of self with location-identifying information removed.
     * Always clears the NetworkRegistrationInfo's CellIdentity fields, but if removeCoarseLocation