pub fn create_seal_merkle_tree() -> SealMerkleTree
Expand description
Create a new seal merkle tree.
This is a convenience function that creates an empty seal merkle tree.
Use SealMerkleTree::from_payment_roots()
to create a tree with existing payment roots.
§Returns
- Empty seal merkle tree
§Example
use miracle_api::sdk::create_seal_merkle_tree;
let mut seal_tree = create_seal_merkle_tree();
seal_tree.add_payment_root([1u8; 32]);
println!("Seal root: {:?}", seal_tree.root());