Private
constructorProtected
configProtected
hasherProtected
keyProtected
rootProtected
storeProtected
valueStatic
initialInitial empty tree root based on poseidon hash algorithm
SparseMerkleTree
Delete a value from tree and return the new root of the tree.
{Promise
SparseMerkleTree
Protected
digestPrivate
getCheck if the key exists in the tree.
{Promise
SparseMerkleTree
Create a merkle proof for a key against the current root.
{Promise
SparseMerkleTree
Create a compacted merkle proof for a key against the current root.
{Promise
SparseMerkleTree
Protected
proveProtected
sideProtected
updateProtected
updateOptional
value: VStatic
buildBuild a new sparse merkle tree
Optional
options: { hasher: The hash function to use, defaults to PoseidonHasherFunc; hashKey: whether to hash the key, the default is true; hashValue: whether to hash the value, the default is true.
Optional
hashOptional
hashOptional
hasher?: Hasher{Promise<SparseMerkleTree<K, V>>}
SparseMerkleTree
Static
importImport a sparse merkle tree via existing store
Optional
options: { hasher: The hash function to use, defaults to PoseidonHasherFunc; hashKey: whether to hash the key, the default is true; hashValue: whether to hash the value, the default is true.
Optional
hashOptional
hashOptional
hasher?: Hasher{Promise<SparseMerkleTree<K, V>>}
SparseMerkleTree
Sparse Merkle Tree
SparseMerkleTree