Versions in this module Expand all Collapse all v0 v0.9.0 Sep 26, 2019 Changes in this version + var ErrContractNotFound = errors.New("contract not found") + func IsSignedBySelf(sealHash common.Hash, signature []byte) bool + func ReloadCBFTParams() + func SetBackend(blockChain *core.BlockChain, txPool *core.TxPool) + func SetBlockChainCache(blockChainCache *core.BlockChainCache) + type API struct + func (api *API) GetProducer(number *rpc.BlockNumber) (common.Address, error) + type BlockExt struct + func NewBlockExt(block *types.Block, blockNum uint64) *BlockExt + type CBFTProduceBlockCfg struct + BlockInterval int32 + ProduceDuration int32 + type Cbft struct + func New(config *params.CbftConfig, blockSignatureCh chan *cbfttypes.BlockSignature, ...) *Cbft + func (b *Cbft) SealHash(header *types.Header) common.Hash + func (cbft *Cbft) APIs(chain consensus.ChainReader) []rpc.API + func (cbft *Cbft) Author(header *types.Header) (common.Address, error) + func (cbft *Cbft) CheckConsensusNode(nodeID discover.NodeID) (bool, error) + func (cbft *Cbft) Close() error + func (cbft *Cbft) ConsensusNodes() ([]discover.NodeID, error) + func (cbft *Cbft) Finalize(chain consensus.ChainReader, header *types.Header, state *state.StateDB, ...) (*types.Block, error) + func (cbft *Cbft) GetBlock(hash common.Hash, number uint64) *types.Block + func (cbft *Cbft) HighestConfirmedBlock() *types.Block + func (cbft *Cbft) HighestLogicalBlock() *types.Block + func (cbft *Cbft) IsConsensusNode() (bool, error) + func (cbft *Cbft) IsPrimaryNode() bool + func (cbft *Cbft) OnBlockSignature(chain consensus.ChainReader, nodeID discover.NodeID, ...) error + func (cbft *Cbft) OnBlockSynced() + func (cbft *Cbft) OnNewBlock(chain consensus.ChainReader, rcvBlock *types.Block) error + func (cbft *Cbft) OnPong(nodeID discover.NodeID, netLatency int64) error + func (cbft *Cbft) Prepare(chain consensus.ChainReader, header *types.Header) error + func (cbft *Cbft) Seal(chain consensus.ChainReader, block *types.Block, ...) (*types.Block, error) + func (cbft *Cbft) SetPrivateKey(privateKey *ecdsa.PrivateKey) + func (cbft *Cbft) ShouldSeal() (bool, error) + func (cbft *Cbft) VerifyHeader(chain consensus.ChainReader, header *types.Header, seal bool) error + func (cbft *Cbft) VerifyHeaders(chain consensus.ChainReader, headers []*types.Header, seals []bool) (chan<- struct{}, <-chan error) + func (cbft *Cbft) VerifySeal(chain consensus.ChainReader, header *types.Header) error + type FlowControl struct + func NewFlowControl() *FlowControl