Class MemPatriciaExtensionNode
java.lang.Object
com.norswap.nanoeth.trees.patricia.PatriciaNode
com.norswap.nanoeth.trees.patricia.PatriciaExtensionNode
com.norswap.nanoeth.trees.patricia.memory.MemPatriciaExtensionNode
public final class MemPatriciaExtensionNode extends PatriciaExtensionNode
An extension node in the in-memory patricia tree.
-
Field Summary
Fields Modifier and Type Field Description PatriciaBranchNode
child
Nibbles
keyFragment
Fields inherited from class com.norswap.nanoeth.trees.patricia.PatriciaNode
cap
-
Constructor Summary
Constructors Constructor Description MemPatriciaExtensionNode(Nibbles keyFragment, PatriciaBranchNode child)
-
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
-
Field Details
-
keyFragment
-
child
-
-
Constructor Details
-
MemPatriciaExtensionNode
-
-
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
-