org.sigilaris.core.codec.byte
Members list
Type members
Classlikes
Bidirectional byte codec combining encoder and decoder.
Bidirectional byte codec combining encoder and decoder.
ByteCodec extends both ByteEncoder and ByteDecoder, providing a single type class for types that support both encoding and decoding.
Most types have both encoder and decoder instances, so ByteCodec is automatically derived when both are available.
Attributes
- See also
-
ByteEncoder for encoding operations
ByteDecoder for decoding operations
types.md for encoding/decoding rules per type
- Companion
- object
- Source
- ByteCodec.scala
- Supertypes
- Known subtypes
-
trait OrderedCodec[A]
- Self type
-
ByteCodec[A]
Attributes
- Companion
- trait
- Source
- ByteCodec.scala
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
ByteCodec.type
Type class for decoding byte sequences to Scala values.
Type class for decoding byte sequences to Scala values.
ByteDecoder is the inverse of ByteEncoder, reconstructing typed values from deterministic byte representations.
Decoding returns Either[DecodeFailure, DecodeResult[A]]:
- Left(failure): decoding failed with error message
- Right(result): successfully decoded value with remaining bytes
The remainder allows sequential decoding of multiple values from a single byte sequence.
Attributes
- See also
-
ByteEncoder for the encoding operation
ByteCodec for bidirectional encoding/decoding
types.md for detailed decoding rules per type
- Companion
- object
- Source
- ByteDecoder.scala
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
Attributes
- Companion
- trait
- Source
- ByteDecoder.scala
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
ByteDecoder.type
Type class for encoding Scala values to deterministic byte sequences.
Type class for encoding Scala values to deterministic byte sequences.
ByteEncoder provides type-safe encoding of Scala data structures into ByteVector representations suitable for blockchain applications such as transaction signing, block hashing, and merkle tree construction.
The encoding is deterministic: the same value always produces the same byte sequence, ensuring consistency across different platforms and nodes.
Attributes
- See also
-
ByteDecoder for the inverse operation
ByteCodec for bidirectional encoding/decoding
types.md for detailed encoding rules per type
- Companion
- object
- Source
- ByteEncoder.scala
- Supertypes
-
class Objecttrait Matchableclass Any
- Known subtypes
Attributes
- Companion
- trait
- Source
- ByteEncoder.scala
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
ByteEncoder.type
Result of a decoding operation.
Result of a decoding operation.
Value parameters
- remainder
-
remaining bytes after decoding
- value
-
the decoded value
Attributes
- Source
- ByteDecoder.scala
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass AnyShow all