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

Commit f091b429 authored by Omair Kamil's avatar Omair Kamil Committed by Gerrit Code Review
Browse files

Merge "Update connections data structure in ContextMap to be an ArrayList." into main

parents 9135a4b0 2408a923
Loading
Loading
Loading
Loading
+4 −5
Original line number Diff line number Diff line
@@ -204,8 +204,9 @@ public class ContextMap<C, T> {
    private final EvictingQueue<AppAdvertiseStats> mLastAdvertises =
            EvictingQueue.create(ADVERTISE_STATE_MAX_SIZE);

    /** Internal list of connected devices **/
    private Set<Connection> mConnections = new HashSet<Connection>();
    /** Internal list of connected devices */
    private List<Connection> mConnections = new ArrayList<Connection>();

    private final Object mConnectionsLock = new Object();

    /** Add an entry to the application context list. */
@@ -384,9 +385,7 @@ public class ContextMap<C, T> {
        return app;
    }

    /**
     * Get an application context by the calling Apps name.
     */
    /** Get an application context by the calling Apps name. */
    public App getByName(String name) {
        App app = getAppByPredicate(entry -> entry.name.equals(name));
        if (app == null) {