BranchWithData

org.sigilaris.core.merkle.MerkleTrieNode.BranchWithData
final case class BranchWithData(prefix: Nibbles, children: Children, value: ByteVector) extends MerkleTrieNode

Branch node with both child nodes and a value.

Value parameters

children

array of 16 optional child node hashes

prefix

the common prefix for all children

value

the value stored at this branch

Attributes

Source
MerkleTrieNode.scala
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Inherited methods

def getChildren: Option[Children]

Returns the children array if this node has children.

Returns the children array if this node has children.

Attributes

Returns

Some(children) for Branch or BranchWithData, None for Leaf

Inherited from:
MerkleTrieNode
Source
MerkleTrieNode.scala
def getValue: Option[ByteVector]

Returns the value stored in this node if present.

Returns the value stored in this node if present.

Attributes

Returns

Some(value) for Leaf or BranchWithData, None for Branch

Inherited from:
MerkleTrieNode
Source
MerkleTrieNode.scala
def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product

Returns a new node with the updated children.

Returns a new node with the updated children.

Value parameters

children

the new children array

Attributes

Returns

node with updated children

Inherited from:
MerkleTrieNode
Source
MerkleTrieNode.scala

Returns a new node with the updated prefix.

Returns a new node with the updated prefix.

Value parameters

prefix

the new prefix

Attributes

Returns

node with updated prefix

Inherited from:
MerkleTrieNode
Source
MerkleTrieNode.scala
def setValue(value: ByteVector): MerkleTrieNode

Returns a new node with the updated value.

Returns a new node with the updated value.

Value parameters

value

the new value

Attributes

Returns

node with updated value

Inherited from:
MerkleTrieNode
Source
MerkleTrieNode.scala
override def toString: String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns

a string representation of the object.

Definition Classes
Inherited from:
MerkleTrieNode
Source
MerkleTrieNode.scala