Merge "Replace LinkedList by a more performant collection"
This commit is contained in:
committed by
Android (Google) Code Review
commit
4df30a7e6f
@@ -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")
|
||||
|
||||
@@ -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}.
|
||||
|
||||
Reference in New Issue
Block a user