supply

package
v0.0.0-...-2bf3886 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 6, 2021 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const BucketName = "org.ffconsulting.tg.db.ETH_SUPPLY.v2"

Variables

View Source
var (
	StageID = stages.SyncStage("org.ffconsulting.ETH_SUPPLY.v2")
)

Functions

func CalculateBackward

func CalculateBackward(db ethdb.Database, from, to uint64) error

func CalculateForward

func CalculateForward(db ethdb.Database, from, to uint64) error

CalculateForwards calculates the ETH supply between blocks `from` and `to` forward in time. (from the smaller block to the larger one) It is more efficient for the smaller block gaps because it doesn't calculate the current state supply. On larger block gaps it is inefficient because of many DB calls.

func DeleteSupplyForBlock

func DeleteSupplyForBlock(db ethdb.Deleter, blockNumber uint64) error

func GetInitialPosition

func GetInitialPosition(db ethdb.Database, from uint64, initialSupply *uint256.Int) (uint64, error)

func GetSupplyForBlock

func GetSupplyForBlock(db ethdb.Getter, blockNumber uint64) (*uint256.Int, error)

func SetSupplyForBlock

func SetSupplyForBlock(db ethdb.Putter, blockNumber uint64, supply *uint256.Int) error

func SyncStage

func SyncStage(ctx *cli.Context) stagedsync.StageBuilder

func Unwind

func Unwind(db ethdb.Database, from, to uint64) (err error)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL