tuweni / org.apache.tuweni.kademlia / kotlin.ByteArray

Extensions for kotlin.ByteArray

xorDist

Determine the XOR-distance between this and an equal-length byte array.

infix fun ByteArray.xorDist(other: ByteArray): Int

xorDistCmp

Compare two equal-length byte arrays for their XOR-distance to this.

fun ByteArray.xorDistCmp(a: ByteArray, b: ByteArray): Int