Merge "Replace LinkedList by a more performant collection"

This commit is contained in:
TreeHugger Robot
2022-02-24 19:13:50 +00:00
committed by Android (Google) Code Review
2 changed files with 3 additions and 4 deletions

View File

@@ -60,7 +60,6 @@ import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.Objects;
@@ -484,7 +483,7 @@ public final class TvInputManager {
private final Object mLock = new Object();
// @GuardedBy("mLock")
private final List<TvInputCallbackRecord> mCallbackRecords = new LinkedList<>();
private final List<TvInputCallbackRecord> mCallbackRecords = new ArrayList<>();
// A mapping from TV input ID to the state of corresponding input.
// @GuardedBy("mLock")

View File

@@ -51,8 +51,8 @@ import com.android.internal.util.Preconditions;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.List;
import java.util.concurrent.Executor;
@@ -293,7 +293,7 @@ public final class TvInteractiveAppManager {
new SparseArray<>();
// @GuardedBy("mLock")
private final List<TvInteractiveAppCallbackRecord> mCallbackRecords = new LinkedList<>();
private final List<TvInteractiveAppCallbackRecord> mCallbackRecords = new ArrayList<>();
// A sequence number for the next session to be created. Should be protected by a lock
// {@code mSessionCallbackRecordMap}.