Crate hash_db[][src]

Expand description

Database of byte-slices keyed to their hash.


An empty prefix constant. Can be use when the prefix is not use internally or for root nodes.


Upcast trait for HashDB.

Upcast trait for PlainDB.

Trait modelling datastore keyed by a hash defined by the Hasher.

Trait for immutable reference of HashDB.

Trait describing an object that can hash a slice of bytes. Used to abstract other types over the hashing algorithm. Defines a single hash method and an Out associated type with the necessary bounds.

Trait modelling a plain datastore whose key is a fixed type. The caller should ensure that a key only corresponds to one value.

Trait for immutable reference of PlainDB.

Type Definitions

A trie node prefix, it is the nibble path from the trie root to the trie node. For a node containing no partial key value it is the full key. For a value node or node containing a partial key, it is the full key minus its node partial nibbles (the node key can be split into prefix and node partial). Therefore it is always the leftmost portion of the node key, so its internal representation is a non expanded byte slice followed by a last padded byte representation. The padded byte is an optional padded value.