decodeUInt24

fun ByteArray.decodeUInt24(octetIndex: Int, byteOrder: ByteOrder): UInt24

Decodes a ByteArray into an UInt24 using the 3 bytes starting from octetIndex

Return

the decoded UInt24

Parameters

octetIndex

the the index of the octet start the decoding from. Must be be at most the third to last octet

byteOrder

the ByteOrder in which the UInt24 is encoded

Throws

if octetIndex or its next two octets are not available in the ByteArray