Supports decoding a value of type A
from a BitVector
.
Attributes
- Companion
- object
- Source
- Decoder.scala
- Graph
-
- Supertypes
- Known subtypes
-
trait Codec[A]
- Self type
-
Decoder[A]
Members list
Value members
Abstract methods
Attempts to decode a value of type A
from the specified bit vector.
Attempts to decode a value of type A
from the specified bit vector.
Value parameters
- bits
-
bits to decode
Attributes
- Returns
-
error if value could not be decoded or the remaining bits and the decoded value
- Source
- Decoder.scala
Concrete methods
Attributes
- Source
- Decoder.scala
Gets this as a Decoder
.
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.
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.
Attributes
- Source
- Decoder.scala
Converts this decoder to a new decoder that fails decoding if there are remaining bits.
Converts this decoder to a new decoder that fails decoding if there are remaining bits.
Attributes
- Source
- Decoder.scala
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.
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.
Attributes
- Returns
-
tuple consisting of the terminating error if any and the accumulated value
- Source
- Decoder.scala
Converts this to a codec that fails encoding with an error.
Attempts to decode a value of type A
from the specified bit vector and discards the remaining bits.
Attempts to decode a value of type A
from the specified bit vector and discards the remaining bits.
Value parameters
- bits
-
bits to decode
Attributes
- Returns
-
error if value could not be decoded or the decoded value
- Source
- Decoder.scala
Converts this decoder to a Decoder[B]
using the supplied A => Attempt[B]
.
Converts this decoder to a Decoder[B]
using the supplied A => Attempt[B]
.
Attributes
- Source
- Decoder.scala
Converts this decoder to a Decoder[B]
using the supplied A => Decoder[B]
.
Converts this decoder to a Decoder[B]
using the supplied A => Decoder[B]
.
Attributes
- Source
- Decoder.scala
Converts this decoder to a Decoder[B]
using the supplied A => B
.