@Test public void testRepairEntriesAreEqual() throws UnknownHostException { RepairEntry repairEntry = new RepairEntry(new LongTokenRange(0, 1), 5, Sets.newHashSet(InetAddress.getLocalHost()), "SUCCESS"); RepairEntry repairEntry2 = new RepairEntry(new LongTokenRange(0, 1), 5, Sets.newHashSet(InetAddress.getLocalHost()), "SUCCESS"); assertThat(repairEntry).isEqualTo(repairEntry2); assertThat(repairEntry.hashCode()).isEqualTo(repairEntry2.hashCode()); }
@Override public int hashCode() { return Objects.hash(myRange, myStartedAt, myParticipants, myStatus); }
RepairEntry { @Override public int hashCode() { return Objects.hash(myRange, myStartedAt, myParticipants, myStatus); } }
RepairEntry { @Override public int hashCode() { return Objects.hash(myRange, myStartedAt, myParticipants, myStatus); } RepairEntry(LongTokenRange range, long startedAt, Set<InetAddress> participants, String status); }
RepairEntry { @Override public int hashCode() { return Objects.hash(myRange, myStartedAt, myParticipants, myStatus); } RepairEntry(LongTokenRange range, long startedAt, Set<InetAddress> participants, String status); LongTokenRange getRange(); long getStartedAt(); Set<InetAddress> getParticipants(); RepairStatus getStatus(); @Override boolean equals(Object o); @Override int hashCode(); }
RepairEntry { @Override public int hashCode() { return Objects.hash(myRange, myStartedAt, myParticipants, myStatus); } RepairEntry(LongTokenRange range, long startedAt, Set<InetAddress> participants, String status); LongTokenRange getRange(); long getStartedAt(); Set<InetAddress> getParticipants(); RepairStatus getStatus(); @Override boolean equals(Object o); @Override int hashCode();  }