SmartPool represent smartpool protocol which interacts smartpool high level interfaces and types together to do following procedures: 1. Register the miner if needed 2. Give miner works 3. Accept solutions from miners and construct corresponding shares to add into current active claim. It returns tr
| 27 | // 5. Then Submit the claim to the contract |
| 28 | // 6. Then If successful, submit the claim proof to the contract. |
| 29 | type SmartPool struct { |
| 30 | PoolMonitor smartpool.PoolMonitor |
| 31 | ShareReceiver smartpool.ShareReceiver |
| 32 | NetworkClient smartpool.NetworkClient |
| 33 | Contract smartpool.Contract |
| 34 | ClaimRepo ClaimRepo |
| 35 | LatestCounter *big.Int |
| 36 | ContractAddress common.Address |
| 37 | MinerAddress common.Address |
| 38 | ExtraData string |
| 39 | SubmitInterval time.Duration |
| 40 | ShareThreshold int |
| 41 | HotStop bool |
| 42 | loopStarted bool |
| 43 | ticker <-chan time.Time |
| 44 | counterMu sync.RWMutex |
| 45 | runMu sync.Mutex |
| 46 | } |
| 47 | |
| 48 | // Register registers miner address to the contract. |
| 49 | // It returns false if the miner address couldn't be able to register to the |
nothing calls this directly
no outgoing calls
no test coverage detected