Crate canonical[][src]

Expand description

Build Status Repository Documentation

Canonical

A no_std, host-allocating serialization library

Structs

Id

This is the Id type, that uniquely identifies slices of bytes, in rust equivalent to &[u8]. As in the case with &[u8] the length is also encoded in the type, making it a kind of a fat-pointer for content adressed byteslices.

Repr

A Repr to a value that is either local or in storage behind an identifier

Sink

Struct used in Canon::encode to read bytes from a buffer

Source

Struct used in Canon::decode to read bytes from a buffer

Store

Low-level intefrace to the store logic.

Val

A reference to a value behind a Repr

ValMut

A mutable reference to a value behind a Repr

Enums

CanonError

The possible errors when fetching/decoding values from a store

Traits

Canon

Trait to read/write values as bytes

EncodeToVec

Helper trait to encode Canon types into byte vectors.

Type Definitions

IdHash

Type alias for a payload that is used as a hash