bytesDifference

fun bytesDifference(priorTerm: BytesRef, currentTerm: BytesRef?): Int

Compares two BytesRef, element by element, and returns the number of elements common to both arrays (from the start of each). This method assumes currentTerm comes after priorTerm.

Return

The number of common elements (from the start of each).

Parameters

priorTerm

The first BytesRef to compare

currentTerm

The second BytesRef to compare