@Test public void hashCodeTest() { FieldValue a = FieldValue.create(1, -100); FieldValue b = FieldValue.create(1, -100); assertEquals(a.hashCode(), b.hashCode()); assertNotEquals(a.hashCode(), FieldValue.DEFAULT.hashCode()); }
@Override public int hashCode() { if (this.defaultFieldValue) { return new HashCodeBuilder(31, 47).append(true).toHashCode(); } return new HashCodeBuilder(31, 47) .append(this.columnID) .append(this.columnKey) .append(this.value) .toHashCode(); }
FieldValue implements Record { @Override public int hashCode() { if (this.defaultFieldValue) { return new HashCodeBuilder(31, 47).append(true).toHashCode(); } return new HashCodeBuilder(31, 47) .append(this.columnID) .append(this.columnKey) .append(this.value) .toHashCode(); } }
FieldValue implements Record { @Override public int hashCode() { if (this.defaultFieldValue) { return new HashCodeBuilder(31, 47).append(true).toHashCode(); } return new HashCodeBuilder(31, 47) .append(this.columnID) .append(this.columnKey) .append(this.value) .toHashCode(); } private  FieldValue(); }
FieldValue implements Record { @Override public int hashCode() { if (this.defaultFieldValue) { return new HashCodeBuilder(31, 47).append(true).toHashCode(); } return new HashCodeBuilder(31, 47) .append(this.columnID) .append(this.columnKey) .append(this.value) .toHashCode(); } private  FieldValue(); static FieldValue create(long columnID, long value); static FieldValue create(String columnKey, long value); long getColumnID(); String getColumnKey(); long getValue(); @Override long shard(long shardWidth); @Override boolean isDefault(); @Override int compareTo(Record record); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); }
FieldValue implements Record { @Override public int hashCode() { if (this.defaultFieldValue) { return new HashCodeBuilder(31, 47).append(true).toHashCode(); } return new HashCodeBuilder(31, 47) .append(this.columnID) .append(this.columnKey) .append(this.value) .toHashCode(); } private  FieldValue(); static FieldValue create(long columnID, long value); static FieldValue create(String columnKey, long value); long getColumnID(); String getColumnKey(); long getValue(); @Override long shard(long shardWidth); @Override boolean isDefault(); @Override int compareTo(Record record); @Override boolean equals(Object o); @Override int hashCode(); @Override String toString(); static final FieldValue DEFAULT; }