Class: Leaf ​
Defined in: leaf.ts:9
Implements ​
Constructors ​
Constructor ​
new Leaf(
value,sumValue,hasher):Leaf
Defined in: leaf.ts:12
Parameters ​
value ​
Uint8Array
sumValue ​
bigint
hasher ​
Returns ​
Leaf
Methods ​
copy() ​
copy():
Node
Defined in: leaf.ts:33
copy performs a deep copy (or "computed" reference). In real usage, you might store partial subtrees or do a shallow copy.
Returns ​
Implementation of ​
getHash() ​
getHash():
Uint8Array
Defined in: leaf.ts:18
getHash returns the Merkle hash of this node.
Returns ​
Uint8Array
Implementation of ​
getSum() ​
getSum():
bigint
Defined in: leaf.ts:29
getSum returns the 64-bit sum that this node contributes upward.
Returns ​
bigint
Implementation of ​
isEmpty() ​
isEmpty():
boolean
Defined in: leaf.ts:43
Returns ​
boolean