read

fun <T : Any> BinarySerializer<T>.read(bytes: ByteArray, strict: Boolean = true): T?

Reads a value of type T from bytes.

Throws

if strict is true and the byte array contains more data than was read