geth

package
v0.0.0-...-c598841 Latest Latest
Warning

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

Go to latest
Published: Mar 22, 2023 License: BSD-4-Clause, MIT Imports: 25 Imported by: 0

Documentation

Index

Constants

View Source
const PoolMonitorClientABI = "" /* 743-byte string literal not displayed */

PoolMonitorClientABI is the input ABI used to generate the binding from.

View Source
const TestClientABI = "" /* 1449-byte string literal not displayed */

TestClientABI is the input ABI used to generate the binding from.

View Source
const TestPoolABI = "" /* 8157-byte string literal not displayed */

TestPoolABI is the input ABI used to generate the binding from.

Variables

View Source
var BlockTime = 6 * time.Second
View Source
var ErrorMap = map[uint64][]string{
	0x80000000: []string{"register", "miner id is already in use", "miner id"},
	0x80000001: []string{"register", "payment address 0 is forbiden", ""},
	0x81000000: []string{"submitClaim", "miner is not registered", ""},
	0x81000001: []string{"submitClaim", "min counter is too low", "last submission counter value"},
	0x82000000: []string{"setEpochData", "only owner can set data", "msg.sender"},
	0x82000001: []string{"setEpochData", "epoch already set", "epoch number"},
	0x83000000: []string{"verifyExtraData", "miner id not as expected", "miner id"},
	0x83000001: []string{"verifyExtraData", "difficulty is not as expected", "encoded difficulty"},
	0x84000000: []string{"verifyClaim", "contract balance is too low to pay", "payment"},
	0x84000001: []string{"verifyClaim", "claim seed is 0", ""},
	0x84000002: []string{"verifyClaim", "share index is not as expected", "expected index"},
	0x84000003: []string{"verifyClaim", "there are no pending claims", ""},
	0x84000004: []string{"verifyClaim", "extra data not as expected", "extra data"},
	0x84000005: []string{"verifyClaim", "coinbase not as expected", "coinbase"},
	0x84000006: []string{"verifyClaim", "counter is smaller than min", "counter"},
	0x84000007: []string{"verifyClaim", "counter is smaller than max", "counter"},
	0x84000008: []string{"verifyClaim", "verification of augmented merkle tree failed", ""},
	0x84000009: []string{"verifyClaim", "ethash difficulty too low (or hashimoto verification failed)", "computed ethash value"},
	0x8400000a: []string{"verifyClaim", "epoch data was not set", "epoch number"},
}
View Source
var RegisterEventTopic = common.HexToHash("0x1d759fb22634fe2d322d688a4b46aaf185dd0a3db78ccf01a9218f00ac3df03f").Big()
View Source
var SetEpochDataEventTopic = common.HexToHash("0x5cd723400be8430351b9cbaa5ea421b3fb2528c6a7650c493f895e7d97750da1").Big()
View Source
var SubmitClaimEventTopic = common.HexToHash("0x53ab9d877ae22286591454f9a8d58501caa34a07c99eac2c09bc0066c065400d").Big()
View Source
var TimestampFile = getTimestampFile()
View Source
var VerifyClaimEventTopic = common.HexToHash("0x096caf97202169a068288f02e51ff9fcc85f98e1477f6ad9acbf6ebf25dbcd00").Big()

Functions

func ErrorMsg

func ErrorMsg(errCode, errInfo *big.Int) string

func GetAddress

func GetAddress(keystorePath string, address common.Address) (common.Address, bool, []common.Address)

Types

type GethContractClient

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

func NewGethContractClient

func NewGethContractClient(
	contractAddr common.Address, node ethereum.RPCClient, miner common.Address,
	ipc, keystorePath, passphrase string) (*GethContractClient, error)

func (*GethContractClient) CanRegister

func (cc *GethContractClient) CanRegister() bool

func (*GethContractClient) GetClaimSeed

func (cc *GethContractClient) GetClaimSeed() *big.Int

func (*GethContractClient) IsRegistered

func (cc *GethContractClient) IsRegistered() bool

func (*GethContractClient) Register

func (cc *GethContractClient) Register(paymentAddress common.Address) error

func (*GethContractClient) SetEpochData

func (cc *GethContractClient) SetEpochData(
	epoch *big.Int,
	fullSizeIn128Resolution *big.Int,
	branchDepth *big.Int,
	merkleNodes []*big.Int) error

func (*GethContractClient) SubmitClaim

func (cc *GethContractClient) SubmitClaim(
	numShares *big.Int,
	difficulty *big.Int,
	min *big.Int,
	max *big.Int,
	augMerkle *big.Int) error

func (*GethContractClient) VerifyClaim

func (cc *GethContractClient) VerifyClaim(
	rlpHeader []byte,
	nonce *big.Int,
	shareIndex *big.Int,
	dataSetLookup []*big.Int,
	witnessForLookup []*big.Int,
	augCountersBranch []*big.Int,
	augHashesBranch []*big.Int) error

func (*GethContractClient) Version

func (cc *GethContractClient) Version() string

type GethRPC

type GethRPC struct {
	ContractAddr    common.Address
	ExtraData       []byte
	ShareDifficulty *big.Int
	MinerAddress    string
	// contains filtered or unexported fields
}

func NewGethRPC

func NewGethRPC(endpoint, contractAddr, extraData string, diff *big.Int, miner string) (*GethRPC, error)

func (*GethRPC) BlockNumber

func (g *GethRPC) BlockNumber() (*big.Int, error)

func (*GethRPC) Broadcast

func (g *GethRPC) Broadcast(data []byte) (common.Hash, error)

func (*GethRPC) ClientVersion

func (g *GethRPC) ClientVersion() (string, error)

func (*GethRPC) GetBlockHeader

func (g *GethRPC) GetBlockHeader(number int) *types.Header

func (*GethRPC) GetLog

func (g *GethRPC) GetLog(
	from *big.Int, event *big.Int,
	sender *big.Int) (*big.Int, *big.Int)

func (*GethRPC) GetPendingBlockHeader

func (g *GethRPC) GetPendingBlockHeader() *types.Header

func (*GethRPC) GetWork

func (g *GethRPC) GetWork() *ethereum.Work

func (*GethRPC) IsVerified

func (g *GethRPC) IsVerified(h common.Hash) bool

func (*GethRPC) SetEtherbase

func (g *GethRPC) SetEtherbase(etherbase common.Address) error

func (*GethRPC) SetExtradata

func (g *GethRPC) SetExtradata(extradata string) error

func (*GethRPC) SubmitHashrate

func (g *GethRPC) SubmitHashrate(hashrate hexutil.Uint64, id common.Hash) bool

func (*GethRPC) SubmitWork

func (g *GethRPC) SubmitWork(nonce types.BlockNonce, hash, mixDigest common.Hash) bool

func (*GethRPC) Syncing

func (g *GethRPC) Syncing() bool

type KovanRPC

type KovanRPC struct {
	*GethRPC
	// contains filtered or unexported fields
}

func NewKovanRPC

func NewKovanRPC(endpoint, contractAddr, extraData string, diff *big.Int, miner string) (*KovanRPC, error)

func (*KovanRPC) GetWork

func (k *KovanRPC) GetWork() *ethereum.Work

func (*KovanRPC) SubmitWork

func (k *KovanRPC) SubmitWork(nonce types.BlockNonce, hash, mixDigest common.Hash) bool

never submit solution to the node because in Kovan, miners can't propose blocks

type MinerAccount

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

func GetAccount

func GetAccount(keystorePath string, address common.Address, passphrase string) *MinerAccount

Get the first account in key store Return nil if there's no account

func (MinerAccount) Address

func (ma MinerAccount) Address() common.Address

func (MinerAccount) KeyFile

func (ma MinerAccount) KeyFile() string

func (MinerAccount) PassPhrase

func (ma MinerAccount) PassPhrase() string

type PoolMonitor

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

func NewPoolMonitor

func NewPoolMonitor(
	gatewayAddr common.Address, contractAddr common.Address,
	version string, ipc string) (*PoolMonitor, error)

func (*PoolMonitor) ContractAddress

func (pm *PoolMonitor) ContractAddress() common.Address

func (*PoolMonitor) RequireClientUpdate

func (pm *PoolMonitor) RequireClientUpdate() bool

func (*PoolMonitor) RequireContractUpdate

func (pm *PoolMonitor) RequireContractUpdate() bool

type PoolMonitorClient

type PoolMonitorClient struct {
	PoolMonitorClientCaller     // Read-only binding to the contract
	PoolMonitorClientTransactor // Write-only binding to the contract
}

PoolMonitorClient is an auto generated Go binding around an Ethereum contract.

func NewPoolMonitorClient

func NewPoolMonitorClient(address common.Address, backend bind.ContractBackend) (*PoolMonitorClient, error)

NewPoolMonitorClient creates a new instance of PoolMonitorClient, bound to a specific deployed contract.

type PoolMonitorClientCaller

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

PoolMonitorClientCaller is an auto generated read-only Go binding around an Ethereum contract.

func NewPoolMonitorClientCaller

func NewPoolMonitorClientCaller(address common.Address, caller bind.ContractCaller) (*PoolMonitorClientCaller, error)

NewPoolMonitorClientCaller creates a new read-only instance of PoolMonitorClient, bound to a specific deployed contract.

func (*PoolMonitorClientCaller) ClientVersion

func (_PoolMonitorClient *PoolMonitorClientCaller) ClientVersion(opts *bind.CallOpts) ([32]byte, error)

ClientVersion is a free data retrieval call binding the contract method 0x044c1d4d.

Solidity: function clientVersion() constant returns(bytes32)

func (*PoolMonitorClientCaller) PoolContract

func (_PoolMonitorClient *PoolMonitorClientCaller) PoolContract(opts *bind.CallOpts) (common.Address, error)

PoolContract is a free data retrieval call binding the contract method 0x88d52ef7.

Solidity: function poolContract() constant returns(address)

type PoolMonitorClientCallerRaw

type PoolMonitorClientCallerRaw struct {
	Contract *PoolMonitorClientCaller // Generic read-only contract binding to access the raw methods on
}

PoolMonitorClientCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.

func (*PoolMonitorClientCallerRaw) Call

func (_PoolMonitorClient *PoolMonitorClientCallerRaw) Call(opts *bind.CallOpts, result interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

type PoolMonitorClientCallerSession

type PoolMonitorClientCallerSession struct {
	Contract *PoolMonitorClientCaller // Generic contract caller binding to set the session for
	CallOpts bind.CallOpts            // Call options to use throughout this session
}

PoolMonitorClientCallerSession is an auto generated read-only Go binding around an Ethereum contract, with pre-set call options.

func (*PoolMonitorClientCallerSession) ClientVersion

func (_PoolMonitorClient *PoolMonitorClientCallerSession) ClientVersion() ([32]byte, error)

ClientVersion is a free data retrieval call binding the contract method 0x044c1d4d.

Solidity: function clientVersion() constant returns(bytes32)

func (*PoolMonitorClientCallerSession) PoolContract

func (_PoolMonitorClient *PoolMonitorClientCallerSession) PoolContract() (common.Address, error)

PoolContract is a free data retrieval call binding the contract method 0x88d52ef7.

Solidity: function poolContract() constant returns(address)

type PoolMonitorClientRaw

type PoolMonitorClientRaw struct {
	Contract *PoolMonitorClient // Generic contract binding to access the raw methods on
}

PoolMonitorClientRaw is an auto generated low-level Go binding around an Ethereum contract.

func (*PoolMonitorClientRaw) Call

func (_PoolMonitorClient *PoolMonitorClientRaw) Call(opts *bind.CallOpts, result interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

func (*PoolMonitorClientRaw) Transact

func (_PoolMonitorClient *PoolMonitorClientRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*PoolMonitorClientRaw) Transfer

func (_PoolMonitorClient *PoolMonitorClientRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type PoolMonitorClientSession

type PoolMonitorClientSession struct {
	Contract     *PoolMonitorClient // Generic contract binding to set the session for
	CallOpts     bind.CallOpts      // Call options to use throughout this session
	TransactOpts bind.TransactOpts  // Transaction auth options to use throughout this session
}

PoolMonitorClientSession is an auto generated Go binding around an Ethereum contract, with pre-set call and transact options.

func (*PoolMonitorClientSession) ClientVersion

func (_PoolMonitorClient *PoolMonitorClientSession) ClientVersion() ([32]byte, error)

ClientVersion is a free data retrieval call binding the contract method 0x044c1d4d.

Solidity: function clientVersion() constant returns(bytes32)

func (*PoolMonitorClientSession) PoolContract

func (_PoolMonitorClient *PoolMonitorClientSession) PoolContract() (common.Address, error)

PoolContract is a free data retrieval call binding the contract method 0x88d52ef7.

Solidity: function poolContract() constant returns(address)

func (*PoolMonitorClientSession) UpdateClientVersion

func (_PoolMonitorClient *PoolMonitorClientSession) UpdateClientVersion(version [32]byte) (*types.Transaction, error)

UpdateClientVersion is a paid mutator transaction binding the contract method 0x03e9598c.

Solidity: function updateClientVersion(version bytes32) returns()

func (*PoolMonitorClientSession) UpdatePoolContract

func (_PoolMonitorClient *PoolMonitorClientSession) UpdatePoolContract(newAddress common.Address) (*types.Transaction, error)

UpdatePoolContract is a paid mutator transaction binding the contract method 0xff1d9dd4.

Solidity: function updatePoolContract(newAddress address) returns()

type PoolMonitorClientTransactor

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

PoolMonitorClientTransactor is an auto generated write-only Go binding around an Ethereum contract.

func NewPoolMonitorClientTransactor

func NewPoolMonitorClientTransactor(address common.Address, transactor bind.ContractTransactor) (*PoolMonitorClientTransactor, error)

NewPoolMonitorClientTransactor creates a new write-only instance of PoolMonitorClient, bound to a specific deployed contract.

func (*PoolMonitorClientTransactor) UpdateClientVersion

func (_PoolMonitorClient *PoolMonitorClientTransactor) UpdateClientVersion(opts *bind.TransactOpts, version [32]byte) (*types.Transaction, error)

UpdateClientVersion is a paid mutator transaction binding the contract method 0x03e9598c.

Solidity: function updateClientVersion(version bytes32) returns()

func (*PoolMonitorClientTransactor) UpdatePoolContract

func (_PoolMonitorClient *PoolMonitorClientTransactor) UpdatePoolContract(opts *bind.TransactOpts, newAddress common.Address) (*types.Transaction, error)

UpdatePoolContract is a paid mutator transaction binding the contract method 0xff1d9dd4.

Solidity: function updatePoolContract(newAddress address) returns()

type PoolMonitorClientTransactorRaw

type PoolMonitorClientTransactorRaw struct {
	Contract *PoolMonitorClientTransactor // Generic write-only contract binding to access the raw methods on
}

PoolMonitorClientTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.

func (*PoolMonitorClientTransactorRaw) Transact

func (_PoolMonitorClient *PoolMonitorClientTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*PoolMonitorClientTransactorRaw) Transfer

func (_PoolMonitorClient *PoolMonitorClientTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type PoolMonitorClientTransactorSession

type PoolMonitorClientTransactorSession struct {
	Contract     *PoolMonitorClientTransactor // Generic contract transactor binding to set the session for
	TransactOpts bind.TransactOpts            // Transaction auth options to use throughout this session
}

PoolMonitorClientTransactorSession is an auto generated write-only Go binding around an Ethereum contract, with pre-set transact options.

func (*PoolMonitorClientTransactorSession) UpdateClientVersion

func (_PoolMonitorClient *PoolMonitorClientTransactorSession) UpdateClientVersion(version [32]byte) (*types.Transaction, error)

UpdateClientVersion is a paid mutator transaction binding the contract method 0x03e9598c.

Solidity: function updateClientVersion(version bytes32) returns()

func (*PoolMonitorClientTransactorSession) UpdatePoolContract

func (_PoolMonitorClient *PoolMonitorClientTransactorSession) UpdatePoolContract(newAddress common.Address) (*types.Transaction, error)

UpdatePoolContract is a paid mutator transaction binding the contract method 0xff1d9dd4.

Solidity: function updatePoolContract(newAddress address) returns()

type TestClient

type TestClient struct {
	TestClientCaller     // Read-only binding to the contract
	TestClientTransactor // Write-only binding to the contract
}

TestClient is an auto generated Go binding around an Ethereum contract.

func NewTestClient

func NewTestClient(address common.Address, backend bind.ContractBackend) (*TestClient, error)

NewTestClient creates a new instance of TestClient, bound to a specific deployed contract.

type TestClientCaller

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

TestClientCaller is an auto generated read-only Go binding around an Ethereum contract.

func NewTestClientCaller

func NewTestClientCaller(address common.Address, caller bind.ContractCaller) (*TestClientCaller, error)

NewTestClientCaller creates a new read-only instance of TestClient, bound to a specific deployed contract.

func (*TestClientCaller) ComputeCacheRoot

func (_TestClient *TestClientCaller) ComputeCacheRoot(opts *bind.CallOpts, index *big.Int, indexInElementsArray *big.Int, elements []*big.Int, witness []*big.Int, branchSize *big.Int) (*big.Int, error)

ComputeCacheRoot is a free data retrieval call binding the contract method 0x3aa4868a.

Solidity: function computeCacheRoot(index uint256, indexInElementsArray uint256, elements uint256[], witness uint256[], branchSize uint256) constant returns(uint256)

func (*TestClientCaller) ComputeLeaf

func (_TestClient *TestClientCaller) ComputeLeaf(opts *bind.CallOpts, dataSetLookup []*big.Int, index *big.Int) (*big.Int, error)

ComputeLeaf is a free data retrieval call binding the contract method 0x275ccb13.

Solidity: function computeLeaf(dataSetLookup uint256[], index uint256) constant returns(uint256)

func (*TestClientCaller) TestOptimization

func (_TestClient *TestClientCaller) TestOptimization(opts *bind.CallOpts, dagIndices []*big.Int, dagElements []*big.Int, witnessArray []*big.Int, epoch *big.Int) ([4]*big.Int, error)

TestOptimization is a free data retrieval call binding the contract method 0x1b8a090a.

Solidity: function testOptimization(dagIndices uint256[], dagElements uint256[], witnessArray uint256[], epoch uint256) constant returns(uint256[4])

type TestClientCallerRaw

type TestClientCallerRaw struct {
	Contract *TestClientCaller // Generic read-only contract binding to access the raw methods on
}

TestClientCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.

func (*TestClientCallerRaw) Call

func (_TestClient *TestClientCallerRaw) Call(opts *bind.CallOpts, result interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

type TestClientCallerSession

type TestClientCallerSession struct {
	Contract *TestClientCaller // Generic contract caller binding to set the session for
	CallOpts bind.CallOpts     // Call options to use throughout this session
}

TestClientCallerSession is an auto generated read-only Go binding around an Ethereum contract, with pre-set call options.

func (*TestClientCallerSession) ComputeCacheRoot

func (_TestClient *TestClientCallerSession) ComputeCacheRoot(index *big.Int, indexInElementsArray *big.Int, elements []*big.Int, witness []*big.Int, branchSize *big.Int) (*big.Int, error)

ComputeCacheRoot is a free data retrieval call binding the contract method 0x3aa4868a.

Solidity: function computeCacheRoot(index uint256, indexInElementsArray uint256, elements uint256[], witness uint256[], branchSize uint256) constant returns(uint256)

func (*TestClientCallerSession) ComputeLeaf

func (_TestClient *TestClientCallerSession) ComputeLeaf(dataSetLookup []*big.Int, index *big.Int) (*big.Int, error)

ComputeLeaf is a free data retrieval call binding the contract method 0x275ccb13.

Solidity: function computeLeaf(dataSetLookup uint256[], index uint256) constant returns(uint256)

func (*TestClientCallerSession) TestOptimization

func (_TestClient *TestClientCallerSession) TestOptimization(dagIndices []*big.Int, dagElements []*big.Int, witnessArray []*big.Int, epoch *big.Int) ([4]*big.Int, error)

TestOptimization is a free data retrieval call binding the contract method 0x1b8a090a.

Solidity: function testOptimization(dagIndices uint256[], dagElements uint256[], witnessArray uint256[], epoch uint256) constant returns(uint256[4])

type TestClientRaw

type TestClientRaw struct {
	Contract *TestClient // Generic contract binding to access the raw methods on
}

TestClientRaw is an auto generated low-level Go binding around an Ethereum contract.

func (*TestClientRaw) Call

func (_TestClient *TestClientRaw) Call(opts *bind.CallOpts, result interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

func (*TestClientRaw) Transact

func (_TestClient *TestClientRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*TestClientRaw) Transfer

func (_TestClient *TestClientRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type TestClientSession

type TestClientSession struct {
	Contract     *TestClient       // Generic contract binding to set the session for
	CallOpts     bind.CallOpts     // Call options to use throughout this session
	TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}

TestClientSession is an auto generated Go binding around an Ethereum contract, with pre-set call and transact options.

func (*TestClientSession) ComputeCacheRoot

func (_TestClient *TestClientSession) ComputeCacheRoot(index *big.Int, indexInElementsArray *big.Int, elements []*big.Int, witness []*big.Int, branchSize *big.Int) (*big.Int, error)

ComputeCacheRoot is a free data retrieval call binding the contract method 0x3aa4868a.

Solidity: function computeCacheRoot(index uint256, indexInElementsArray uint256, elements uint256[], witness uint256[], branchSize uint256) constant returns(uint256)

func (*TestClientSession) ComputeLeaf

func (_TestClient *TestClientSession) ComputeLeaf(dataSetLookup []*big.Int, index *big.Int) (*big.Int, error)

ComputeLeaf is a free data retrieval call binding the contract method 0x275ccb13.

Solidity: function computeLeaf(dataSetLookup uint256[], index uint256) constant returns(uint256)

func (*TestClientSession) SetOptEpochData

func (_TestClient *TestClientSession) SetOptEpochData(epoch *big.Int, fullSizeIn128Resultion *big.Int, branchDepth *big.Int, merkleNodes []*big.Int, start *big.Int, numElems *big.Int) (*types.Transaction, error)

SetOptEpochData is a paid mutator transaction binding the contract method 0x7e043973.

Solidity: function setOptEpochData(epoch uint256, fullSizeIn128Resultion uint256, branchDepth uint256, merkleNodes uint256[], start uint256, numElems uint256) returns()

func (*TestClientSession) TestOptimization

func (_TestClient *TestClientSession) TestOptimization(dagIndices []*big.Int, dagElements []*big.Int, witnessArray []*big.Int, epoch *big.Int) ([4]*big.Int, error)

TestOptimization is a free data retrieval call binding the contract method 0x1b8a090a.

Solidity: function testOptimization(dagIndices uint256[], dagElements uint256[], witnessArray uint256[], epoch uint256) constant returns(uint256[4])

type TestClientTransactor

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

TestClientTransactor is an auto generated write-only Go binding around an Ethereum contract.

func NewTestClientTransactor

func NewTestClientTransactor(address common.Address, transactor bind.ContractTransactor) (*TestClientTransactor, error)

NewTestClientTransactor creates a new write-only instance of TestClient, bound to a specific deployed contract.

func (*TestClientTransactor) SetOptEpochData

func (_TestClient *TestClientTransactor) SetOptEpochData(opts *bind.TransactOpts, epoch *big.Int, fullSizeIn128Resultion *big.Int, branchDepth *big.Int, merkleNodes []*big.Int, start *big.Int, numElems *big.Int) (*types.Transaction, error)

SetOptEpochData is a paid mutator transaction binding the contract method 0x7e043973.

Solidity: function setOptEpochData(epoch uint256, fullSizeIn128Resultion uint256, branchDepth uint256, merkleNodes uint256[], start uint256, numElems uint256) returns()

type TestClientTransactorRaw

type TestClientTransactorRaw struct {
	Contract *TestClientTransactor // Generic write-only contract binding to access the raw methods on
}

TestClientTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.

func (*TestClientTransactorRaw) Transact

func (_TestClient *TestClientTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*TestClientTransactorRaw) Transfer

func (_TestClient *TestClientTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type TestClientTransactorSession

type TestClientTransactorSession struct {
	Contract     *TestClientTransactor // Generic contract transactor binding to set the session for
	TransactOpts bind.TransactOpts     // Transaction auth options to use throughout this session
}

TestClientTransactorSession is an auto generated write-only Go binding around an Ethereum contract, with pre-set transact options.

func (*TestClientTransactorSession) SetOptEpochData

func (_TestClient *TestClientTransactorSession) SetOptEpochData(epoch *big.Int, fullSizeIn128Resultion *big.Int, branchDepth *big.Int, merkleNodes []*big.Int, start *big.Int, numElems *big.Int) (*types.Transaction, error)

SetOptEpochData is a paid mutator transaction binding the contract method 0x7e043973.

Solidity: function setOptEpochData(epoch uint256, fullSizeIn128Resultion uint256, branchDepth uint256, merkleNodes uint256[], start uint256, numElems uint256) returns()

type TestPool

type TestPool struct {
	TestPoolCaller     // Read-only binding to the contract
	TestPoolTransactor // Write-only binding to the contract
}

TestPool is an auto generated Go binding around an Ethereum contract.

func NewTestPool

func NewTestPool(address common.Address, backend bind.ContractBackend) (*TestPool, error)

NewTestPool creates a new instance of TestPool, bound to a specific deployed contract.

type TestPoolCaller

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

TestPoolCaller is an auto generated read-only Go binding around an Ethereum contract.

func NewTestPoolCaller

func NewTestPoolCaller(address common.Address, caller bind.ContractCaller) (*TestPoolCaller, error)

NewTestPoolCaller creates a new read-only instance of TestPool, bound to a specific deployed contract.

func (*TestPoolCaller) CanRegister

func (_TestPool *TestPoolCaller) CanRegister(opts *bind.CallOpts, sender common.Address) (bool, error)

CanRegister is a free data retrieval call binding the contract method 0x320d46d4.

Solidity: function canRegister(sender address) constant returns(bool)

func (*TestPoolCaller) CreationBlockNumber

func (_TestPool *TestPoolCaller) CreationBlockNumber(opts *bind.CallOpts) (*big.Int, error)

CreationBlockNumber is a free data retrieval call binding the contract method 0x1bf30929.

Solidity: function creationBlockNumber() constant returns(uint256)

func (*TestPoolCaller) EpochData

func (_TestPool *TestPoolCaller) EpochData(opts *bind.CallOpts, arg0 *big.Int) (struct {
	MerkleRoot             *big.Int
	FullSizeIn128Resultion uint64
	BranchDepth            uint64
}, error)

EpochData is a free data retrieval call binding the contract method 0x6e821b2e.

Solidity: function epochData( uint256) constant returns(merkleRoot uint128, fullSizeIn128Resultion uint64, branchDepth uint64)

func (*TestPoolCaller) ExistingIds

func (_TestPool *TestPoolCaller) ExistingIds(opts *bind.CallOpts, arg0 [32]byte) (bool, error)

ExistingIds is a free data retrieval call binding the contract method 0xee385304.

Solidity: function existingIds( bytes32) constant returns(bool)

func (*TestPoolCaller) ExtraBalance

func (_TestPool *TestPoolCaller) ExtraBalance(opts *bind.CallOpts) (*big.Int, error)

ExtraBalance is a free data retrieval call binding the contract method 0x21b5b8dd.

Solidity: function extraBalance() constant returns(uint256)

func (*TestPoolCaller) GetClaimSeed

func (_TestPool *TestPoolCaller) GetClaimSeed(opts *bind.CallOpts, sender common.Address) (*big.Int, error)

GetClaimSeed is a free data retrieval call binding the contract method 0x7087ed2c.

Solidity: function getClaimSeed(sender address) constant returns(uint256)

func (*TestPoolCaller) GetMerkleLeave

func (_TestPool *TestPoolCaller) GetMerkleLeave(opts *bind.CallOpts, epochIndex *big.Int, p *big.Int) (*big.Int, error)

GetMerkleLeave is a free data retrieval call binding the contract method 0x7dcfd508.

Solidity: function getMerkleLeave(epochIndex uint256, p uint256) constant returns(uint256)

func (*TestPoolCaller) GetMerkleNode

func (_TestPool *TestPoolCaller) GetMerkleNode(opts *bind.CallOpts, epoch *big.Int, node *big.Int) (*big.Int, error)

GetMerkleNode is a free data retrieval call binding the contract method 0xa331a964.

Solidity: function getMerkleNode(epoch uint256, node uint256) constant returns(uint256)

func (*TestPoolCaller) GetMinerId

func (_TestPool *TestPoolCaller) GetMinerId(opts *bind.CallOpts, sender common.Address) ([32]byte, error)

GetMinerId is a free data retrieval call binding the contract method 0xe2dea715.

Solidity: function getMinerId(sender address) constant returns(bytes32)

func (*TestPoolCaller) GetShareIndex

func (_TestPool *TestPoolCaller) GetShareIndex(opts *bind.CallOpts, sender common.Address) (*big.Int, error)

GetShareIndex is a free data retrieval call binding the contract method 0x0f136527.

Solidity: function getShareIndex(sender address) constant returns(uint256)

func (*TestPoolCaller) Hashimoto

func (_TestPool *TestPoolCaller) Hashimoto(opts *bind.CallOpts, header [32]byte, nonceLe [8]byte, dataSetLookup []*big.Int, witnessForLookup []*big.Int, epochIndex *big.Int) (*big.Int, error)

Hashimoto is a free data retrieval call binding the contract method 0x40ed79f4.

Solidity: function hashimoto(header bytes32, nonceLe bytes8, dataSetLookup uint256[], witnessForLookup uint256[], epochIndex uint256) constant returns(uint256)

func (*TestPoolCaller) IsRegistered

func (_TestPool *TestPoolCaller) IsRegistered(opts *bind.CallOpts, sender common.Address) (bool, error)

IsRegistered is a free data retrieval call binding the contract method 0xc3c5a547.

Solidity: function isRegistered(sender address) constant returns(bool)

func (*TestPoolCaller) NewVersionReleased

func (_TestPool *TestPoolCaller) NewVersionReleased(opts *bind.CallOpts) (bool, error)

NewVersionReleased is a free data retrieval call binding the contract method 0x0289e966.

Solidity: function newVersionReleased() constant returns(bool)

func (*TestPoolCaller) Owners

func (_TestPool *TestPoolCaller) Owners(opts *bind.CallOpts, arg0 common.Address) (bool, error)

Owners is a free data retrieval call binding the contract method 0x022914a7.

Solidity: function owners( address) constant returns(bool)

func (*TestPoolCaller) SubsidyFactor

func (_TestPool *TestPoolCaller) SubsidyFactor(opts *bind.CallOpts) (*big.Int, error)

SubsidyFactor is a free data retrieval call binding the contract method 0xdeb53645.

Solidity: function subsidyFactor() constant returns(uint256)

func (*TestPoolCaller) To62Encoding

func (_TestPool *TestPoolCaller) To62Encoding(opts *bind.CallOpts, id *big.Int, numChars *big.Int) ([32]byte, error)

To62Encoding is a free data retrieval call binding the contract method 0xff5d2c39.

Solidity: function to62Encoding(id uint256, numChars uint256) constant returns(bytes32)

func (*TestPoolCaller) Version

func (_TestPool *TestPoolCaller) Version(opts *bind.CallOpts) (string, error)

Version is a free data retrieval call binding the contract method 0x54fd4d50.

Solidity: function version() constant returns(string)

type TestPoolCallerRaw

type TestPoolCallerRaw struct {
	Contract *TestPoolCaller // Generic read-only contract binding to access the raw methods on
}

TestPoolCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract.

func (*TestPoolCallerRaw) Call

func (_TestPool *TestPoolCallerRaw) Call(opts *bind.CallOpts, result interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

type TestPoolCallerSession

type TestPoolCallerSession struct {
	Contract *TestPoolCaller // Generic contract caller binding to set the session for
	CallOpts bind.CallOpts   // Call options to use throughout this session
}

TestPoolCallerSession is an auto generated read-only Go binding around an Ethereum contract, with pre-set call options.

func (*TestPoolCallerSession) CanRegister

func (_TestPool *TestPoolCallerSession) CanRegister(sender common.Address) (bool, error)

CanRegister is a free data retrieval call binding the contract method 0x320d46d4.

Solidity: function canRegister(sender address) constant returns(bool)

func (*TestPoolCallerSession) CreationBlockNumber

func (_TestPool *TestPoolCallerSession) CreationBlockNumber() (*big.Int, error)

CreationBlockNumber is a free data retrieval call binding the contract method 0x1bf30929.

Solidity: function creationBlockNumber() constant returns(uint256)

func (*TestPoolCallerSession) EpochData

func (_TestPool *TestPoolCallerSession) EpochData(arg0 *big.Int) (struct {
	MerkleRoot             *big.Int
	FullSizeIn128Resultion uint64
	BranchDepth            uint64
}, error)

EpochData is a free data retrieval call binding the contract method 0x6e821b2e.

Solidity: function epochData( uint256) constant returns(merkleRoot uint128, fullSizeIn128Resultion uint64, branchDepth uint64)

func (*TestPoolCallerSession) ExistingIds

func (_TestPool *TestPoolCallerSession) ExistingIds(arg0 [32]byte) (bool, error)

ExistingIds is a free data retrieval call binding the contract method 0xee385304.

Solidity: function existingIds( bytes32) constant returns(bool)

func (*TestPoolCallerSession) ExtraBalance

func (_TestPool *TestPoolCallerSession) ExtraBalance() (*big.Int, error)

ExtraBalance is a free data retrieval call binding the contract method 0x21b5b8dd.

Solidity: function extraBalance() constant returns(uint256)

func (*TestPoolCallerSession) GetClaimSeed

func (_TestPool *TestPoolCallerSession) GetClaimSeed(sender common.Address) (*big.Int, error)

GetClaimSeed is a free data retrieval call binding the contract method 0x7087ed2c.

Solidity: function getClaimSeed(sender address) constant returns(uint256)

func (*TestPoolCallerSession) GetMerkleLeave

func (_TestPool *TestPoolCallerSession) GetMerkleLeave(epochIndex *big.Int, p *big.Int) (*big.Int, error)

GetMerkleLeave is a free data retrieval call binding the contract method 0x7dcfd508.

Solidity: function getMerkleLeave(epochIndex uint256, p uint256) constant returns(uint256)

func (*TestPoolCallerSession) GetMerkleNode

func (_TestPool *TestPoolCallerSession) GetMerkleNode(epoch *big.Int, node *big.Int) (*big.Int, error)

GetMerkleNode is a free data retrieval call binding the contract method 0xa331a964.

Solidity: function getMerkleNode(epoch uint256, node uint256) constant returns(uint256)

func (*TestPoolCallerSession) GetMinerId

func (_TestPool *TestPoolCallerSession) GetMinerId(sender common.Address) ([32]byte, error)

GetMinerId is a free data retrieval call binding the contract method 0xe2dea715.

Solidity: function getMinerId(sender address) constant returns(bytes32)

func (*TestPoolCallerSession) GetShareIndex

func (_TestPool *TestPoolCallerSession) GetShareIndex(sender common.Address) (*big.Int, error)

GetShareIndex is a free data retrieval call binding the contract method 0x0f136527.

Solidity: function getShareIndex(sender address) constant returns(uint256)

func (*TestPoolCallerSession) Hashimoto

func (_TestPool *TestPoolCallerSession) Hashimoto(header [32]byte, nonceLe [8]byte, dataSetLookup []*big.Int, witnessForLookup []*big.Int, epochIndex *big.Int) (*big.Int, error)

Hashimoto is a free data retrieval call binding the contract method 0x40ed79f4.

Solidity: function hashimoto(header bytes32, nonceLe bytes8, dataSetLookup uint256[], witnessForLookup uint256[], epochIndex uint256) constant returns(uint256)

func (*TestPoolCallerSession) IsRegistered

func (_TestPool *TestPoolCallerSession) IsRegistered(sender common.Address) (bool, error)

IsRegistered is a free data retrieval call binding the contract method 0xc3c5a547.

Solidity: function isRegistered(sender address) constant returns(bool)

func (*TestPoolCallerSession) NewVersionReleased

func (_TestPool *TestPoolCallerSession) NewVersionReleased() (bool, error)

NewVersionReleased is a free data retrieval call binding the contract method 0x0289e966.

Solidity: function newVersionReleased() constant returns(bool)

func (*TestPoolCallerSession) Owners

func (_TestPool *TestPoolCallerSession) Owners(arg0 common.Address) (bool, error)

Owners is a free data retrieval call binding the contract method 0x022914a7.

Solidity: function owners( address) constant returns(bool)

func (*TestPoolCallerSession) SubsidyFactor

func (_TestPool *TestPoolCallerSession) SubsidyFactor() (*big.Int, error)

SubsidyFactor is a free data retrieval call binding the contract method 0xdeb53645.

Solidity: function subsidyFactor() constant returns(uint256)

func (*TestPoolCallerSession) To62Encoding

func (_TestPool *TestPoolCallerSession) To62Encoding(id *big.Int, numChars *big.Int) ([32]byte, error)

To62Encoding is a free data retrieval call binding the contract method 0xff5d2c39.

Solidity: function to62Encoding(id uint256, numChars uint256) constant returns(bytes32)

func (*TestPoolCallerSession) Version

func (_TestPool *TestPoolCallerSession) Version() (string, error)

Version is a free data retrieval call binding the contract method 0x54fd4d50.

Solidity: function version() constant returns(string)

type TestPoolRaw

type TestPoolRaw struct {
	Contract *TestPool // Generic contract binding to access the raw methods on
}

TestPoolRaw is an auto generated low-level Go binding around an Ethereum contract.

func (*TestPoolRaw) Call

func (_TestPool *TestPoolRaw) Call(opts *bind.CallOpts, result interface{}, method string, params ...interface{}) error

Call invokes the (constant) contract method with params as input values and sets the output to result. The result type might be a single field for simple returns, a slice of interfaces for anonymous returns and a struct for named returns.

func (*TestPoolRaw) Transact

func (_TestPool *TestPoolRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*TestPoolRaw) Transfer

func (_TestPool *TestPoolRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type TestPoolSession

type TestPoolSession struct {
	Contract     *TestPool         // Generic contract binding to set the session for
	CallOpts     bind.CallOpts     // Call options to use throughout this session
	TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session
}

TestPoolSession is an auto generated Go binding around an Ethereum contract, with pre-set call and transact options.

func (*TestPoolSession) CanRegister

func (_TestPool *TestPoolSession) CanRegister(sender common.Address) (bool, error)

CanRegister is a free data retrieval call binding the contract method 0x320d46d4.

Solidity: function canRegister(sender address) constant returns(bool)

func (*TestPoolSession) CreationBlockNumber

func (_TestPool *TestPoolSession) CreationBlockNumber() (*big.Int, error)

CreationBlockNumber is a free data retrieval call binding the contract method 0x1bf30929.

Solidity: function creationBlockNumber() constant returns(uint256)

func (*TestPoolSession) DeclareNewerVersion

func (_TestPool *TestPoolSession) DeclareNewerVersion() (*types.Transaction, error)

DeclareNewerVersion is a paid mutator transaction binding the contract method 0xe3d86998.

Solidity: function declareNewerVersion() returns()

func (*TestPoolSession) EpochData

func (_TestPool *TestPoolSession) EpochData(arg0 *big.Int) (struct {
	MerkleRoot             *big.Int
	FullSizeIn128Resultion uint64
	BranchDepth            uint64
}, error)

EpochData is a free data retrieval call binding the contract method 0x6e821b2e.

Solidity: function epochData( uint256) constant returns(merkleRoot uint128, fullSizeIn128Resultion uint64, branchDepth uint64)

func (*TestPoolSession) ExistingIds

func (_TestPool *TestPoolSession) ExistingIds(arg0 [32]byte) (bool, error)

ExistingIds is a free data retrieval call binding the contract method 0xee385304.

Solidity: function existingIds( bytes32) constant returns(bool)

func (*TestPoolSession) ExtraBalance

func (_TestPool *TestPoolSession) ExtraBalance() (*big.Int, error)

ExtraBalance is a free data retrieval call binding the contract method 0x21b5b8dd.

Solidity: function extraBalance() constant returns(uint256)

func (*TestPoolSession) GetClaimSeed

func (_TestPool *TestPoolSession) GetClaimSeed(sender common.Address) (*big.Int, error)

GetClaimSeed is a free data retrieval call binding the contract method 0x7087ed2c.

Solidity: function getClaimSeed(sender address) constant returns(uint256)

func (*TestPoolSession) GetMerkleLeave

func (_TestPool *TestPoolSession) GetMerkleLeave(epochIndex *big.Int, p *big.Int) (*big.Int, error)

GetMerkleLeave is a free data retrieval call binding the contract method 0x7dcfd508.

Solidity: function getMerkleLeave(epochIndex uint256, p uint256) constant returns(uint256)

func (*TestPoolSession) GetMerkleNode

func (_TestPool *TestPoolSession) GetMerkleNode(epoch *big.Int, node *big.Int) (*big.Int, error)

GetMerkleNode is a free data retrieval call binding the contract method 0xa331a964.

Solidity: function getMerkleNode(epoch uint256, node uint256) constant returns(uint256)

func (*TestPoolSession) GetMinerId

func (_TestPool *TestPoolSession) GetMinerId(sender common.Address) ([32]byte, error)

GetMinerId is a free data retrieval call binding the contract method 0xe2dea715.

Solidity: function getMinerId(sender address) constant returns(bytes32)

func (*TestPoolSession) GetShareIndex

func (_TestPool *TestPoolSession) GetShareIndex(sender common.Address) (*big.Int, error)

GetShareIndex is a free data retrieval call binding the contract method 0x0f136527.

Solidity: function getShareIndex(sender address) constant returns(uint256)

func (*TestPoolSession) Hashimoto

func (_TestPool *TestPoolSession) Hashimoto(header [32]byte, nonceLe [8]byte, dataSetLookup []*big.Int, witnessForLookup []*big.Int, epochIndex *big.Int) (*big.Int, error)

Hashimoto is a free data retrieval call binding the contract method 0x40ed79f4.

Solidity: function hashimoto(header bytes32, nonceLe bytes8, dataSetLookup uint256[], witnessForLookup uint256[], epochIndex uint256) constant returns(uint256)

func (*TestPoolSession) IsRegistered

func (_TestPool *TestPoolSession) IsRegistered(sender common.Address) (bool, error)

IsRegistered is a free data retrieval call binding the contract method 0xc3c5a547.

Solidity: function isRegistered(sender address) constant returns(bool)

func (*TestPoolSession) NewVersionReleased

func (_TestPool *TestPoolSession) NewVersionReleased() (bool, error)

NewVersionReleased is a free data retrieval call binding the contract method 0x0289e966.

Solidity: function newVersionReleased() constant returns(bool)

func (*TestPoolSession) Owners

func (_TestPool *TestPoolSession) Owners(arg0 common.Address) (bool, error)

Owners is a free data retrieval call binding the contract method 0x022914a7.

Solidity: function owners( address) constant returns(bool)

func (*TestPoolSession) Register

func (_TestPool *TestPoolSession) Register(paymentAddress common.Address) (*types.Transaction, error)

Register is a paid mutator transaction binding the contract method 0x4420e486.

Solidity: function register(paymentAddress address) returns()

func (*TestPoolSession) SetEpochData

func (_TestPool *TestPoolSession) SetEpochData(epoch *big.Int, fullSizeIn128Resultion *big.Int, branchDepth *big.Int, merkleNodes []*big.Int, start *big.Int, numElems *big.Int) (*types.Transaction, error)

SetEpochData is a paid mutator transaction binding the contract method 0xc891a29d.

Solidity: function setEpochData(epoch uint256, fullSizeIn128Resultion uint256, branchDepth uint256, merkleNodes uint256[], start uint256, numElems uint256) returns()

func (*TestPoolSession) SetSubsidy

func (_TestPool *TestPoolSession) SetSubsidy(factor *big.Int) (*types.Transaction, error)

SetSubsidy is a paid mutator transaction binding the contract method 0x0e9b6281.

Solidity: function setSubsidy(factor uint256) returns()

func (*TestPoolSession) SubmitClaim

func (_TestPool *TestPoolSession) SubmitClaim(numShares *big.Int, difficulty *big.Int, min *big.Int, max *big.Int, augMerkle *big.Int) (*types.Transaction, error)

SubmitClaim is a paid mutator transaction binding the contract method 0xe7dac983.

Solidity: function submitClaim(numShares uint256, difficulty uint256, min uint256, max uint256, augMerkle uint256) returns()

func (*TestPoolSession) SubsidyFactor

func (_TestPool *TestPoolSession) SubsidyFactor() (*big.Int, error)

SubsidyFactor is a free data retrieval call binding the contract method 0xdeb53645.

Solidity: function subsidyFactor() constant returns(uint256)

func (*TestPoolSession) To62Encoding

func (_TestPool *TestPoolSession) To62Encoding(id *big.Int, numChars *big.Int) ([32]byte, error)

To62Encoding is a free data retrieval call binding the contract method 0xff5d2c39.

Solidity: function to62Encoding(id uint256, numChars uint256) constant returns(bytes32)

func (*TestPoolSession) VerifyClaim

func (_TestPool *TestPoolSession) VerifyClaim(rlpHeader []byte, nonce *big.Int, shareIndex *big.Int, dataSetLookup []*big.Int, witnessForLookup []*big.Int, augCountersBranch []*big.Int, augHashesBranch []*big.Int) (*types.Transaction, error)

VerifyClaim is a paid mutator transaction binding the contract method 0x35ffbe74.

Solidity: function verifyClaim(rlpHeader bytes, nonce uint256, shareIndex uint256, dataSetLookup uint256[], witnessForLookup uint256[], augCountersBranch uint256[], augHashesBranch uint256[]) returns(uint256)

func (*TestPoolSession) Version

func (_TestPool *TestPoolSession) Version() (string, error)

Version is a free data retrieval call binding the contract method 0x54fd4d50.

Solidity: function version() constant returns(string)

type TestPoolTransactor

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

TestPoolTransactor is an auto generated write-only Go binding around an Ethereum contract.

func NewTestPoolTransactor

func NewTestPoolTransactor(address common.Address, transactor bind.ContractTransactor) (*TestPoolTransactor, error)

NewTestPoolTransactor creates a new write-only instance of TestPool, bound to a specific deployed contract.

func (*TestPoolTransactor) DeclareNewerVersion

func (_TestPool *TestPoolTransactor) DeclareNewerVersion(opts *bind.TransactOpts) (*types.Transaction, error)

DeclareNewerVersion is a paid mutator transaction binding the contract method 0xe3d86998.

Solidity: function declareNewerVersion() returns()

func (*TestPoolTransactor) Register

func (_TestPool *TestPoolTransactor) Register(opts *bind.TransactOpts, paymentAddress common.Address) (*types.Transaction, error)

Register is a paid mutator transaction binding the contract method 0x4420e486.

Solidity: function register(paymentAddress address) returns()

func (*TestPoolTransactor) SetEpochData

func (_TestPool *TestPoolTransactor) SetEpochData(opts *bind.TransactOpts, epoch *big.Int, fullSizeIn128Resultion *big.Int, branchDepth *big.Int, merkleNodes []*big.Int, start *big.Int, numElems *big.Int) (*types.Transaction, error)

SetEpochData is a paid mutator transaction binding the contract method 0xc891a29d.

Solidity: function setEpochData(epoch uint256, fullSizeIn128Resultion uint256, branchDepth uint256, merkleNodes uint256[], start uint256, numElems uint256) returns()

func (*TestPoolTransactor) SetSubsidy

func (_TestPool *TestPoolTransactor) SetSubsidy(opts *bind.TransactOpts, factor *big.Int) (*types.Transaction, error)

SetSubsidy is a paid mutator transaction binding the contract method 0x0e9b6281.

Solidity: function setSubsidy(factor uint256) returns()

func (*TestPoolTransactor) SubmitClaim

func (_TestPool *TestPoolTransactor) SubmitClaim(opts *bind.TransactOpts, numShares *big.Int, difficulty *big.Int, min *big.Int, max *big.Int, augMerkle *big.Int) (*types.Transaction, error)

SubmitClaim is a paid mutator transaction binding the contract method 0xe7dac983.

Solidity: function submitClaim(numShares uint256, difficulty uint256, min uint256, max uint256, augMerkle uint256) returns()

func (*TestPoolTransactor) VerifyClaim

func (_TestPool *TestPoolTransactor) VerifyClaim(opts *bind.TransactOpts, rlpHeader []byte, nonce *big.Int, shareIndex *big.Int, dataSetLookup []*big.Int, witnessForLookup []*big.Int, augCountersBranch []*big.Int, augHashesBranch []*big.Int) (*types.Transaction, error)

VerifyClaim is a paid mutator transaction binding the contract method 0x35ffbe74.

Solidity: function verifyClaim(rlpHeader bytes, nonce uint256, shareIndex uint256, dataSetLookup uint256[], witnessForLookup uint256[], augCountersBranch uint256[], augHashesBranch uint256[]) returns(uint256)

type TestPoolTransactorRaw

type TestPoolTransactorRaw struct {
	Contract *TestPoolTransactor // Generic write-only contract binding to access the raw methods on
}

TestPoolTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract.

func (*TestPoolTransactorRaw) Transact

func (_TestPool *TestPoolTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error)

Transact invokes the (paid) contract method with params as input values.

func (*TestPoolTransactorRaw) Transfer

func (_TestPool *TestPoolTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error)

Transfer initiates a plain transaction to move funds to the contract, calling its default method if one is available.

type TestPoolTransactorSession

type TestPoolTransactorSession struct {
	Contract     *TestPoolTransactor // Generic contract transactor binding to set the session for
	TransactOpts bind.TransactOpts   // Transaction auth options to use throughout this session
}

TestPoolTransactorSession is an auto generated write-only Go binding around an Ethereum contract, with pre-set transact options.

func (*TestPoolTransactorSession) DeclareNewerVersion

func (_TestPool *TestPoolTransactorSession) DeclareNewerVersion() (*types.Transaction, error)

DeclareNewerVersion is a paid mutator transaction binding the contract method 0xe3d86998.

Solidity: function declareNewerVersion() returns()

func (*TestPoolTransactorSession) Register

func (_TestPool *TestPoolTransactorSession) Register(paymentAddress common.Address) (*types.Transaction, error)

Register is a paid mutator transaction binding the contract method 0x4420e486.

Solidity: function register(paymentAddress address) returns()

func (*TestPoolTransactorSession) SetEpochData

func (_TestPool *TestPoolTransactorSession) SetEpochData(epoch *big.Int, fullSizeIn128Resultion *big.Int, branchDepth *big.Int, merkleNodes []*big.Int, start *big.Int, numElems *big.Int) (*types.Transaction, error)

SetEpochData is a paid mutator transaction binding the contract method 0xc891a29d.

Solidity: function setEpochData(epoch uint256, fullSizeIn128Resultion uint256, branchDepth uint256, merkleNodes uint256[], start uint256, numElems uint256) returns()

func (*TestPoolTransactorSession) SetSubsidy

func (_TestPool *TestPoolTransactorSession) SetSubsidy(factor *big.Int) (*types.Transaction, error)

SetSubsidy is a paid mutator transaction binding the contract method 0x0e9b6281.

Solidity: function setSubsidy(factor uint256) returns()

func (*TestPoolTransactorSession) SubmitClaim

func (_TestPool *TestPoolTransactorSession) SubmitClaim(numShares *big.Int, difficulty *big.Int, min *big.Int, max *big.Int, augMerkle *big.Int) (*types.Transaction, error)

SubmitClaim is a paid mutator transaction binding the contract method 0xe7dac983.

Solidity: function submitClaim(numShares uint256, difficulty uint256, min uint256, max uint256, augMerkle uint256) returns()

func (*TestPoolTransactorSession) VerifyClaim

func (_TestPool *TestPoolTransactorSession) VerifyClaim(rlpHeader []byte, nonce *big.Int, shareIndex *big.Int, dataSetLookup []*big.Int, witnessForLookup []*big.Int, augCountersBranch []*big.Int, augHashesBranch []*big.Int) (*types.Transaction, error)

VerifyClaim is a paid mutator transaction binding the contract method 0x35ffbe74.

Solidity: function verifyClaim(rlpHeader bytes, nonce uint256, shareIndex uint256, dataSetLookup uint256[], witnessForLookup uint256[], augCountersBranch uint256[], augHashesBranch uint256[]) returns(uint256)

type TxWatcher

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

TxWatcher keeps track of pending transactions and acknowledge corresponding channel when a transaction is confirmed. It also captures event information emitted during the transaction.

func NewTxWatcher

func NewTxWatcher(
	tx *types.Transaction, node ethereum.RPCClient,
	blockNo *big.Int, event *big.Int, sender *big.Int) *TxWatcher

func (*TxWatcher) Wait

func (tw *TxWatcher) Wait() (*big.Int, *big.Int, error)

func (*TxWatcher) WaitAndRetry

func (tw *TxWatcher) WaitAndRetry() (*big.Int, *big.Int, error)

Jump to

Keyboard shortcuts

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