Skip to content

serializeSegmentedTrie<V>(trie, codec, options?): Uint8Array

Defined in: packages/trie/src/serialization/binary.ts:106

Serialize a segmented trie as a shared UTF-8 string table, a depth-first parent-pointer node table, and a parallel terminal-value run.

V

SegmentedTrie<V>

ElementCodec<V>

SerializeSegmentedTrieOptions

Uint8Array

With MISSING_ELEMENT_CODEC when codec is absent, and with INVALID_SEGMENT, INVALID_CODEC_RESULT, NON_INJECTIVE_CODEC, or SERIALIZATION_LIMIT_EXCEEDED when the trie cannot be represented safely.