@Override public long getHighestReceivedVersion() { if (isEmpty()) { return this.previousVersion; } else { // Note, the "length" of the bitset is the highest set bit + 1, // see the javadocs. That's why this works to return the highest // received version return receivedBaseVersion + received.length() - 1; } }