producer

package
v2.13.0 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2023 License: GPL-3.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewProducer

func NewProducer(rw chain.Chain,
	subscriber net.Subscriber,
	coinbase interfaces.Account,
	cs consensus.Subscriber,
	p pool.SnapshotProducerWriter) *producer

todo syncDone

Types

type Producer

type Producer interface {
	SetAccountEventFunc(func(producerevent.AccountEvent))
	Init() error
	Start() error
	Stop() error
	GetCoinBase() types.Address
	SnapshotOnce() error
}

type SnapshotChainRW

type SnapshotChainRW interface {
	WriteMiningBlock(block *ledger.SnapshotBlock) error
}

Backend wraps all methods required for mining.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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