block.go 363 B

123456789101112131415161718192021
  1. package pow
  2. import (
  3. "math/big"
  4. "github.com/ethereum/go-ethereum/common"
  5. "github.com/ethereum/go-ethereum/core/types"
  6. )
  7. type Block interface {
  8. Difficulty() *big.Int
  9. HashNoNonce() common.Hash
  10. Nonce() uint64
  11. MixDigest() common.Hash
  12. NumberU64() uint64
  13. }
  14. type ChainManager interface {
  15. GetBlockByNumber(uint64) *types.Block
  16. CurrentBlock() *types.Block
  17. }