xor

infix fun ByteArray.xor(other: ByteArray): ByteArray

Applies the XOR operator on two byte arrays. Compared to already existent xor functions, this one does not require the arrays to be of the same length.

Return

XOR of the two byte arrays.

Parameters

other

The other byte array which is xor ed with this one.


infix fun Byte.xor(other: Int): Byte

Binary XOR operation on a Byte type.

Receiver

The first byte.

Return

The result of the XOR operation.

Parameters

other

The second byte.


infix fun UByte.xor(other: Int): UByte

Binary XOR operation on a UByte type.

Receiver

The first unsigned byte.

Return

The result of the XOR operation.

Parameters

other

The second byte.


infix fun Short.xor(other: Int): Short

Binary XOR operation on a Short type.

Receiver

The first short.

Return

The result of the XOR operation.

Parameters

other

The second byte.


infix fun UShort.xor(other: Int): UShort

Binary XOR operation on a UShort type.

Receiver

The first unsigned short.

Return

The result of the XOR operation.

Parameters

other

The second byte.