getByteString

fun getByteString(numBytes: Int): ByteString

Reads a ByteString from the byte array and advances the cursor.

Return

A ByteString containing the bytes.

Parameters

numBytes

The number of bytes to read.

Throws

If the numBytes is negative or if the requested range (cursor + numBytes) extends beyond the bounds of the ByteArray.