The core protocol of WoopChain
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
woop/rpc/common/block.go

19 lines
552 B

package common
import (
"github.com/ethereum/go-ethereum/common"
"github.com/woop-chain/woop/core/types"
)
// BlockFactory is the interface of factory for RPC block data
type BlockFactory interface {
NewBlock(b *types.Block, args *BlockArgs) (interface{}, error)
}
// BlockDataProvider helps with providing data for RPC blocks
type BlockDataProvider interface {
GetLeader(b *types.Block) string
GetSigners(b *types.Block) ([]string, error)
GetStakingTxs(b *types.Block) (interface{}, error)
GetStakingTxHashes(b *types.Block) []common.Hash
}