class MerkleTree::Stream
- MerkleTree::Stream
- Reference
- Object
Defined in:
merkle_tree_stream.crConstructors
-
.new(leaf, parent, roots = [] of Node)
Create a new MerkleTreeStream instance
Instance Method Summary
- #blocks : UInt64
-
#leaf : Proc(Node, Array(Node)?, Bytes)
Pass data through a hash function
-
#next(data : Bytes, nodes : Array(Node) = [] of Node) : Array(Node)
Pass a string buffer through the flat-tree hash functions, and write the result back out to "nodes"
-
#parent : Proc(Node, Node, Bytes)
Pass hashes through a hash function
- #roots : Array(Node)
Constructor Detail
Create a new MerkleTreeStream instance
Instance Method Detail
Pass a string buffer through the flat-tree hash functions, and write the result back out to "nodes"