Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PSMT ¶
type PSMT struct {
// contains filtered or unexported fields
}
PSMT (Partial Sparse Merkle Tree) holds a subset of an sparse merkle tree at specific state commitment (no historic views). Instead of keeping any unneeded branch, it only keeps the hash of subtree. This implementation is fully stored in memory and doesn't use a database.
DEFINITIONS and CONVENTIONS:
- HEIGHT of a node v in a tree is the number of edges on the longest downward path between v and a tree leaf. The height of a tree is the heights of its root. The height of a Trie is always the height of the fully-expanded tree.
func NewPSMT ¶
func NewPSMT( rootValue []byte, keyByteSize int, keys [][]byte, values [][]byte, proofs [][]byte, ) (*PSMT, error)
NewPSMT builds a Partial Sparse Merkle Tree (PMST) given a chunkdatapack registertouches
Click to show internal directories.
Click to hide internal directories.