scheduler

package
v0.10.6 Latest Latest
Warning

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

Go to latest
Published: Jun 15, 2023 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Default added in v0.10.4

type Default struct {
	// contains filtered or unexported fields
}

func NewScheduler

func NewScheduler(
	state state.State,
	seeder seeder,
	settings *settings.BlockchainSettings,
	tm types.Time,
	consensus types.MinerConsensus,
	minerDelay time.Duration) (*Default, error)

func (*Default) Emits added in v0.10.4

func (a *Default) Emits() []Emit

func (*Default) Mine added in v0.10.4

func (a *Default) Mine() chan Emit

func (*Default) Reschedule added in v0.10.4

func (a *Default) Reschedule()

type DisabledScheduler added in v0.8.0

type DisabledScheduler struct {
}

func (DisabledScheduler) Emits added in v0.8.0

func (d DisabledScheduler) Emits() []Emit

func (DisabledScheduler) Mine added in v0.8.0

func (d DisabledScheduler) Mine() chan Emit

func (DisabledScheduler) Reschedule added in v0.8.0

func (d DisabledScheduler) Reschedule()

type Emit

type Emit struct {
	Timestamp    uint64
	KeyPair      proto.KeyPair
	GenSignature []byte
	VRF          []byte
	BaseTarget   types.BaseTarget
	Parent       proto.BlockID
}

type MinerConsensusImpl added in v0.5.0

type MinerConsensusImpl struct {
	// contains filtered or unexported fields
}

func NewMinerConsensus added in v0.5.0

func NewMinerConsensus(c connectedCount, atLeastConnectedPeers int) MinerConsensusImpl

func (MinerConsensusImpl) IsMiningAllowed added in v0.5.0

func (a MinerConsensusImpl) IsMiningAllowed() bool

type StubConsensus added in v0.5.0

type StubConsensus struct {
}

func (StubConsensus) IsMiningAllowed added in v0.5.0

func (s StubConsensus) IsMiningAllowed() bool

Jump to

Keyboard shortcuts

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