miner

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Apr 3, 2020 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FeaturesToInt16 added in v0.5.0

func FeaturesToInt16(a []settings.Feature) []int16

func MineBlock added in v0.5.0

func MineBlock(version proto.BlockVersion, nxt proto.NxtConsensus, pair proto.KeyPair, validatedFeatured Features, t proto.Timestamp, parent proto.BlockID, reward int64, scheme proto.Scheme) (*proto.Block, error)

func ParseReward added in v0.5.0

func ParseReward(s string) (int64, error)

func Run

Types

type Constraints

type Constraints struct {
	MaxScriptRunsInBlock        int
	MaxScriptsComplexityInBlock int
	ClassicAmountOfTxsInBlock   int
	MaxTxsSizeInBytes           int
}

func DefaultConstraints

func DefaultConstraints() Constraints

type Features added in v0.5.0

type Features []settings.Feature

func ParseVoteFeatures added in v0.5.0

func ParseVoteFeatures(s string) (Features, error)

func ValidateFeaturesWithLock added in v0.5.0

func ValidateFeaturesWithLock(state state.State, features Features) (Features, error)

func ValidateFeaturesWithoutLock added in v0.5.0

func ValidateFeaturesWithoutLock(state state.State, features Features) (Features, error)

type MicroblockMiner

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

func NewMicroblockMiner

func NewMicroblockMiner(services services.Services, ngRuntime ng.Runtime, features Features, reward int64) *MicroblockMiner

func (*MicroblockMiner) Mine

func (a *MicroblockMiner) Mine(ctx context.Context, t proto.Timestamp, k proto.KeyPair, parent proto.BlockID, baseTarget types.BaseTarget, gs []byte, vrf []byte)

Directories

Path Synopsis
Package utxpool is a generated GoMock package.
Package utxpool is a generated GoMock package.

Jump to

Keyboard shortcuts

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