ByteFieldComparatorImpl extends AbstractFieldComparator<ENTITY> implements ByteFieldComparator<ENTITY, D> { @Override public boolean equals(Object obj) { if (this == obj) return true; if (!(obj instanceof FieldComparator)) return false; @SuppressWarnings("unchecked") final FieldComparator<ENTITY> casted = (FieldComparator<ENTITY>) obj; return reversed == casted.isReversed() && Objects.equals( field.identifier(), casted.getField().identifier() ); } ByteFieldComparatorImpl(HasByteValue<ENTITY, D> field);   ByteFieldComparatorImpl(HasByteValue<ENTITY, D> field, boolean reversed); @Override HasByteValue<ENTITY, D> getField(); @Override NullOrder getNullOrder(); @Override boolean isReversed(); @Override ByteFieldComparatorImpl<ENTITY, D> reversed(); @Override int compare(ENTITY first, ENTITY second); @Override int hashCode(); @Override boolean equals(Object obj); @Override String toString();  }
@Test void testEquals() { final ByteFieldComparatorImpl<ByteValue, Byte> result = new ByteFieldComparatorImpl<>(ByteValue.BYTE, false); assertEquals(instance, result); }