level

package
v2.0.0 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2025 License: MIT Imports: 32 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Welcome = true

	ErrIterator = IteratorError(errors.New("iteration error"))
)

Functions

func BatchAppend

func BatchAppend(ctx context.Context, b *leveldb.Batch, rows []tbcd.Row)

BatchAppend appends rows to batch b.

func New

func New(ctx context.Context, cfg *Config) (*ldb, error)

func SetBatchSize

func SetBatchSize(size int)

func SetMode

func SetMode(move bool)

Types

type CMResult

type CMResult struct {
	Records int        // Number of records
	Skipped int        // Number of records skipped
	Size    int        // Total amount of data
	Range   util.Range // Start and Limit of operation
}

type Config

type Config struct {
	BlockCacheSize       string // size of block cache
	BlockheaderCacheSize string // size of block header cache
	Home                 string // home directory
	Network              string // network e.g. "testnet3", "mainnet" etc
	// contains filtered or unexported fields
}

func NewConfig

func NewConfig(network, home, blockheaderCacheSizeS, blockCacheSizeS string) (*Config, error)

func (*Config) SetNoninteractive

func (cfg *Config) SetNoninteractive(x bool)

func (*Config) SetUpgradeOpen

func (cfg *Config) SetUpgradeOpen(x bool)

type IteratorError

type IteratorError error

Jump to

Keyboard shortcuts

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