public boolean isCompact() {
        return position == 0 && array.length == length;
    }
Checks whether the buffer is compact or not. A buffer is compact when
{@code position} points to zero and {@code length} equals to
{@code array().length}.

@return true if the buffer is compact; false otherwise
clickhouse-data/src/main/java/com/clickhouse/data/ClickHouseByteBuffer.java