Class StorePatriciaExtensionNode
java.lang.Object
com.norswap.nanoeth.trees.patricia.PatriciaNode
com.norswap.nanoeth.trees.patricia.PatriciaExtensionNode
com.norswap.nanoeth.trees.patricia.store.StorePatriciaExtensionNode
public final class StorePatriciaExtensionNode extends PatriciaExtensionNode
An extension node usable for store-backed implementation, or for nodes in abridged form.
-
Field Summary
Fields inherited from class com.norswap.nanoeth.trees.patricia.PatriciaNode
cap
-
Constructor Summary
Constructors Constructor Description StorePatriciaExtensionNode(Nibbles keyFragment, byte[] childCap)
-
Method Summary
Modifier and Type Method Description PatriciaBranchNode
child(NodeStore store)
Returns the child node of this extension node.byte[]
childCap()
Returns the cap value ofPatriciaExtensionNode.child(NodeStore)
.boolean
equals(Object o)
int
hashCode()
Nibbles
keyFragment()
Returns the key fragment associated with this node.String
toString()
Methods inherited from class com.norswap.nanoeth.trees.patricia.PatriciaExtensionNode
add, collectEntries, compose, lookup, remove, step, value
Methods inherited from class com.norswap.nanoeth.trees.patricia.PatriciaNode
cap, merkleRoot, parse
-
Constructor Details
-
StorePatriciaExtensionNode
-
-
Method Details
-
keyFragment
Description copied from class:PatriciaExtensionNode
Returns the key fragment associated with this node.- Specified by:
keyFragment
in classPatriciaExtensionNode
-
child
Description copied from class:PatriciaExtensionNode
Returns the child node of this extension node. This should always be a branch node.- Specified by:
child
in classPatriciaExtensionNode
-
childCap
public byte[] childCap()Description copied from class:PatriciaExtensionNode
Returns the cap value ofPatriciaExtensionNode.child(NodeStore)
.This is a separate method because in the abridged representation, the child's cap value is stored directly, but not the child itself.
- Specified by:
childCap
in classPatriciaExtensionNode
-
equals
-
hashCode
public int hashCode() -
toString
-