Supports decoding a value of type A
from a BitVector
.
- Companion
- object
Document{}
Attempts to decode a value of type A
from the specified bit vector.
- Value Params
- bits
bits to decode
- Returns
error if value could not be decoded or the remaining bits and the decoded value
Attempts to decode a value of type A
from the specified bit vector and discards the remaining bits.
- Value Params
- bits
bits to decode
- Returns
error if value could not be decoded or the decoded value
Repeatedly decodes values of type A
from the specified vector, converts each value to a B
and appends it to an accumulator of type
B
using the supplied zero
value and append
function. Terminates when no more bits are available in the vector. Exits upon first decoding error.
- Returns
tuple consisting of the terminating error if any and the accumulated value
Repeatedly decodes values of type A
from the specified vector and returns a collection of the specified type.
Terminates when no more bits are available in the vector or when limit
is defined and that many records have been
decoded. Exits upon first decoding error.