miner

package
v0.8.4 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2015 License: LGPL-2.1-or-later Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Agent added in v0.8.4

type Agent interface {
	Work() chan<- *types.Block
	SetWorkCh(chan<- Work)
	Stop()
	Start()
	Pow() pow.PoW
}

type CpuMiner added in v0.8.4

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

func NewCpuMiner added in v0.8.4

func NewCpuMiner(index int, pow pow.PoW) *CpuMiner

func (*CpuMiner) Pow added in v0.8.4

func (self *CpuMiner) Pow() pow.PoW

func (*CpuMiner) SetWorkCh added in v0.8.4

func (self *CpuMiner) SetWorkCh(ch chan<- Work)

func (*CpuMiner) Start added in v0.8.4

func (self *CpuMiner) Start()

func (*CpuMiner) Stop added in v0.8.4

func (self *CpuMiner) Stop()

func (*CpuMiner) Work added in v0.8.4

func (self *CpuMiner) Work() chan<- *types.Block

type Miner

type Miner struct {
	MinAcceptedGasPrice *big.Int
	Extra               string

	Coinbase []byte
	// contains filtered or unexported fields
}

func New

func New(coinbase []byte, eth core.Backend, minerThreads int) *Miner

func (*Miner) HashRate

func (self *Miner) HashRate() int64

func (*Miner) Mining

func (self *Miner) Mining() bool

func (*Miner) Start

func (self *Miner) Start()

func (*Miner) Stop

func (self *Miner) Stop()

type Work added in v0.8.4

type Work struct {
	Number uint64
	Nonce  []byte
}

Jump to

Keyboard shortcuts

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