@Test public void testEquals() { CountResultItem result1 = createSampleResult(); CountResultItem result2 = createSampleResult(); boolean e = result1.equals(result2); assertTrue(e); }
@Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof CountResultItem)) { return false; } CountResultItem rhs = (CountResultItem) obj; return new EqualsBuilder() .append(this.id, rhs.id) .append(this.key, rhs.key) .append(this.count, rhs.count) .isEquals(); }
CountResultItem { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof CountResultItem)) { return false; } CountResultItem rhs = (CountResultItem) obj; return new EqualsBuilder() .append(this.id, rhs.id) .append(this.key, rhs.key) .append(this.count, rhs.count) .isEquals(); } }
CountResultItem { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof CountResultItem)) { return false; } CountResultItem rhs = (CountResultItem) obj; return new EqualsBuilder() .append(this.id, rhs.id) .append(this.key, rhs.key) .append(this.count, rhs.count) .isEquals(); }  }
CountResultItem { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof CountResultItem)) { return false; } CountResultItem rhs = (CountResultItem) obj; return new EqualsBuilder() .append(this.id, rhs.id) .append(this.key, rhs.key) .append(this.count, rhs.count) .isEquals(); }  long getID(); String getKey(); long getCount(); @Override String toString(); @Override boolean equals(Object obj); @Override int hashCode(); }
CountResultItem { @Override public boolean equals(Object obj) { if (obj == this) { return true; } if (!(obj instanceof CountResultItem)) { return false; } CountResultItem rhs = (CountResultItem) obj; return new EqualsBuilder() .append(this.id, rhs.id) .append(this.key, rhs.key) .append(this.count, rhs.count) .isEquals(); }  long getID(); String getKey(); long getCount(); @Override String toString(); @Override boolean equals(Object obj); @Override int hashCode();  }