Skip to content

U8Codec

[Source]

Read or write a single unsigned byte (8 bits).

primitive val U8Codec is
  Codec[U8 val] val

Implements


Constructors

create

[Source]

new val create()
: U8Codec val^

Returns


Public Functions

decode

[Source]

Decode a single unsigned byte at the given bit offset.

fun box decode(
  data: Array[U8 val] val,
  offset: USize val)
: ((U8 val , USize val) | DecodeError)

Parameters

Returns


encode

[Source]

fun box encode(
  value: U8 val)
: (Array[U8 val] val | EncodeError)

Parameters

  • value: U8 val

Returns


eq

[Source]

fun box eq(
  that: U8Codec val)
: Bool val

Parameters

Returns


ne

[Source]

fun box ne(
  that: U8Codec val)
: Bool val

Parameters

Returns