Versions in this module Expand all Collapse all v1 v1.11.13-rc.2 Dec 4, 2024 v1.0.0 Dec 4, 2024 Changes in this version + type Block interface + SetStatus func(choices.Status) + type BlockWrapper struct + func (bw *BlockWrapper) Accept(ctx context.Context) error + func (bw *BlockWrapper) Reject(ctx context.Context) error + func (bw *BlockWrapper) ShouldVerifyWithContext(ctx context.Context) (bool, error) + func (bw *BlockWrapper) Verify(ctx context.Context) error + func (bw *BlockWrapper) VerifyWithContext(ctx context.Context, blockCtx *block.Context) error + type Config struct + BatchedUnmarshalBlock func(context.Context, [][]byte) ([]snowman.Block, error) + BuildBlock func(context.Context) (snowman.Block, error) + BuildBlockWithContext func(context.Context, *block.Context) (snowman.Block, error) + BytesToIDCacheSize int + DecidedCacheSize int + GetBlock func(context.Context, ids.ID) (snowman.Block, error) + GetBlockIDAtHeight func(context.Context, uint64) (ids.ID, error) + LastAcceptedBlock snowman.Block + MissingCacheSize int + UnmarshalBlock func(context.Context, []byte) (snowman.Block, error) + UnverifiedCacheSize int + type State struct + func NewMeteredState(registerer prometheus.Registerer, config *Config) (*State, error) + func NewState(config *Config) *State + func (s *State) BatchedParseBlock(ctx context.Context, blksBytes [][]byte) ([]snowman.Block, error) + func (s *State) BuildBlock(ctx context.Context) (snowman.Block, error) + func (s *State) BuildBlockWithContext(ctx context.Context, blockCtx *block.Context) (snowman.Block, error) + func (s *State) Flush() + func (s *State) GetBlock(ctx context.Context, blkID ids.ID) (snowman.Block, error) + func (s *State) GetBlockInternal(ctx context.Context, blkID ids.ID) (snowman.Block, error) + func (s *State) IsProcessing(blkID ids.ID) bool + func (s *State) LastAccepted(context.Context) (ids.ID, error) + func (s *State) LastAcceptedBlock() *BlockWrapper + func (s *State) LastAcceptedBlockInternal() snowman.Block + func (s *State) ParseBlock(ctx context.Context, b []byte) (snowman.Block, error) + func (s *State) SetLastAcceptedBlock(lastAcceptedBlock snowman.Block) error