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

Commit bd829910 authored by Etan Cohen's avatar Etan Cohen Committed by android-build-merger
Browse files

Merge "[AWARE] Make PeerHandle comparable/hashable"

am: 8d621cc0

Change-Id: I31a1ebcecd49b620462f2fb917e6c0c0d8f4d06e
parents b9d49781 8d621cc0
Loading
Loading
Loading
Loading
+18 −0
Original line number Diff line number Diff line
@@ -32,4 +32,22 @@ public class PeerHandle {

    /** @hide */
    public int peerId;

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }

        if (!(o instanceof PeerHandle)) {
            return false;
        }

        return peerId == ((PeerHandle) o).peerId;
    }

    @Override
    public int hashCode() {
        return peerId;
    }
}