2019-05-27 13:51:49 +00:00
|
|
|
package main
|
|
|
|
|
|
|
|
import (
|
|
|
|
"math/big"
|
|
|
|
|
|
|
|
"github.com/ledgerwatch/turbo-geth/common"
|
2020-03-25 15:40:30 +00:00
|
|
|
"github.com/ledgerwatch/turbo-geth/core/forkid"
|
2019-05-27 13:51:49 +00:00
|
|
|
"github.com/ledgerwatch/turbo-geth/core/types"
|
|
|
|
)
|
|
|
|
|
|
|
|
type BlockFeeder interface {
|
|
|
|
Close()
|
|
|
|
GetHeaderByHash(hash common.Hash) *types.Header
|
|
|
|
GetHeaderByNumber(number uint64) *types.Header
|
|
|
|
GetBlockByHash(hash common.Hash) (*types.Block, error)
|
2020-03-04 22:25:40 +00:00
|
|
|
GetBlockByNumber(number uint64) (*types.Block, error)
|
|
|
|
GetTdByNumber(number uint64) *big.Int
|
2019-05-27 13:51:49 +00:00
|
|
|
TotalDifficulty() *big.Int
|
|
|
|
LastBlock() *types.Block
|
2020-03-25 15:40:30 +00:00
|
|
|
ForkID() forkid.ID
|
2020-04-06 07:53:52 +00:00
|
|
|
Genesis() *types.Block
|
2019-05-27 13:51:49 +00:00
|
|
|
}
|