@Override
  public int compareTo(ByteArrayWrapper other) {
    if (this == other) {
      return 0;
    }
    int minSize = Math.min(size, other.size);
    for (int i = 0; i < minSize; ++i) {
      if (bytes[i] != other.bytes[i]) {
        return (bytes[i] & 0xFF) - (other.bytes[i] & 0xFF);
      }
    }
    return size - other.size;
  }
Compare this object to another ByteArrayWrapper, which must not be null.

@param other the object to compare to.
@return a value &lt;0, 0, or &gt;0 as this compares less than, equal to, or greater than other.
@throws ClassCastException if the other object is not a ByteArrayWrapper
amoro-format-mixed/amoro-mixed-flink/amoro-mixed-flink-common/src/main/java/org/apache/amoro/flink/lookup/ByteArrayWrapper.java