class MerkleTree::Node

Defined in:

merkle_tree_stream.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(index, parent, size, data, hash) #

[View source]

Instance Method Detail

def data : Bytes #

Data if it's a leaf node, otherwise empty bytes


[View source]
def data=(data : Bytes) #

Data if it's a leaf node, otherwise empty bytes


[View source]
def hash : Bytes? #

Hash of the data


[View source]
def hash=(hash : Bytes?) #

Hash of the data


[View source]
def index : UInt64 #

Offset into the flat-tree data structure


[View source]
def index=(index : UInt64) #

Offset into the flat-tree data structure


[View source]
def parent : UInt64 #

Reference to this node's parent node


[View source]
def parent=(parent : UInt64) #

Reference to this node's parent node


[View source]
def size : UInt64 #

Total size of all its child nodes combined


[View source]
def size=(size : UInt64) #

Total size of all its child nodes combined


[View source]