Categorygithub.com/cerc-io/eth-iterator-utils
modulepackage
0.3.1
Repository: https://github.com/cerc-io/eth-iterator-utils.git
Documentation: pkg.go.dev

# README

go-ethereum iterator utilites

Includes:

  • PrefixBoundIterator for iterating subtries.
  • SubtrieIterators for dividing a state trie into disjoint subtries.
  • tracker package for tracking, dumping and restoring the state of open iterators.

# Packages

This package provides a way to track multiple concurrently running trie iterators, save their state to a file on failures or interruptions, and restore them at the positions where they stopped.

# Functions

No description provided by the author
HexToKeyBytes turns hex nibbles into key bytes.
MakePaths generates paths that cut trie domain into `nbins` uniform conterminous bins (w/ opt.
NewPrefixBoundIterator returns an iterator with an upper bound value (hex path prefix).
SubtrieIterators cuts a trie by path prefix, returning `nbins` iterators covering its subtries.

# Structs

PrefixBoundIterator is a NodeIterator constrained by a lower & upper bound (as hex path prefixes).

# Type aliases

IteratorConstructor is a constructor returning a NodeIterator, which is used to decouple this code from the trie implementation.