miner

package
v0.0.0-...-f7edce5 Latest Latest
Warning

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

Go to latest
Published: May 21, 2018 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Under100Temp = iota
	Exactly100Temp
	Over100Temp
	AcceptedIncrement
	AcceptedSame
	AcceptedZero
	AcceptedError
)

Variables

View Source
var ClientModule = fx.Options(
	cgminer.ClientModule,

	fx.Provide(func(client *cgminer.Wrapper) Client {
		return client
	}),
)
View Source
var VersionModule = fx.Provide(NewVersion)

Functions

This section is empty.

Types

type Client

type Client interface {
	Quit() error
	Restart() error
	GetAccepted() (int64, error)
	GetTemp() (float64, error)
}

type MockMinerClient

type MockMinerClient struct {
	CalledQuit     bool
	CalledRestart  bool
	CalledDevs     bool
	CalledAccepted bool

	Test int
	// contains filtered or unexported fields
}

func NewMockMinerClient

func NewMockMinerClient(test int) MockMinerClient

func (*MockMinerClient) GetAccepted

func (c *MockMinerClient) GetAccepted() (int64, error)

func (*MockMinerClient) GetTemp

func (c *MockMinerClient) GetTemp() (float64, error)

func (*MockMinerClient) Quit

func (c *MockMinerClient) Quit() error

func (*MockMinerClient) Restart

func (c *MockMinerClient) Restart() error

type Version

type Version struct {
	V string
}

func NewVersion

func NewVersion(config agent.Config) Version

ConfigData is currently unused, but in the future on other miners, we might get the version information from another source and we would likely pass that in via the agent config.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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