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

Commit 3707c343 authored by Hunsuk Choi's avatar Hunsuk Choi
Browse files

Rename onCreateExecutor to getCreateExecutor

Make it synchronous per API council's request

Bug: 324064089
Test: atest DomainSelectionServiceTestOnMockModem
Change-Id: I10ff3b41fb811716f03e31f1b415994dda593da2
parent 74bd6d36
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -14192,9 +14192,9 @@ package android.telephony {
  @FlaggedApi("com.android.internal.telephony.flags.use_oem_domain_selection_service") public abstract class DomainSelectionService extends android.app.Service {
    ctor public DomainSelectionService();
    method @NonNull public java.util.concurrent.Executor getCreateExecutor();
    method public void onBarringInfoUpdated(int, int, @NonNull android.telephony.BarringInfo);
    method @Nullable public final android.os.IBinder onBind(@Nullable android.content.Intent);
    method @NonNull public java.util.concurrent.Executor onCreateExecutor();
    method public abstract void onDomainSelection(@NonNull android.telephony.DomainSelectionService.SelectionAttributes, @NonNull android.telephony.TransportSelectorCallback);
    method public void onServiceStateUpdated(int, int, @NonNull android.telephony.ServiceState);
    field public static final int SCAN_TYPE_FULL_SERVICE = 2; // 0x2
+4 −2
Original line number Diff line number Diff line
@@ -20,6 +20,7 @@ import android.annotation.FlaggedApi;
import android.annotation.IntDef;
import android.annotation.NonNull;
import android.annotation.Nullable;
import android.annotation.SuppressLint;
import android.annotation.SystemApi;
import android.app.Service;
import android.content.Intent;
@@ -855,7 +856,8 @@ public abstract class DomainSelectionService extends Service {
     *
     * @return an {@link Executor} used to execute methods called remotely by the framework.
     */
    public @NonNull Executor onCreateExecutor() {
    @SuppressLint("OnNameExpected")
    public @NonNull Executor getCreateExecutor() {
        return Runnable::run;
    }

@@ -869,7 +871,7 @@ public abstract class DomainSelectionService extends Service {
    public final @NonNull Executor getCachedExecutor() {
        synchronized (mExecutorLock) {
            if (mExecutor == null) {
                Executor e = onCreateExecutor();
                Executor e = getCreateExecutor();
                mExecutor = (e != null) ? e : Runnable::run;
            }
            return mExecutor;