class MerkleTree::Stream

Defined in:

merkle_tree_stream.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(leaf, parent, roots = [] of Node) #

Create a new MerkleTreeStream instance


[View source]

Instance Method Detail

def blocks : UInt64 #

[View source]
def leaf : Proc(Node, Array(Node)?, Bytes) #

Pass data through a hash function


[View source]
def 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"


[View source]
def parent : Proc(Node, Node, Bytes) #

Pass hashes through a hash function


[View source]
def roots : Array(Node) #

[View source]