Documentation ¶
Index ¶
- type ChainSpanner
- func (c *ChainSpanner) CommitSpan(ctx context.Context, heimdallSpan HeimdallSpan, state *state.StateDB, ...) error
- func (c *ChainSpanner) GetCurrentSpan(ctx context.Context, headerHash common.Hash) (*Span, error)
- func (c *ChainSpanner) GetCurrentValidators(ctx context.Context, headerHash common.Hash, blockNumber uint64) ([]*valset.Validator, error)
- type HeimdallSpan
- type Span
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChainSpanner ¶
type ChainSpanner struct {
// contains filtered or unexported fields
}
func NewChainSpanner ¶
func NewChainSpanner(ethAPI api.Caller, validatorSet abi.ABI, chainConfig *params.ChainConfig, validatorContractAddress common.Address) *ChainSpanner
func (*ChainSpanner) CommitSpan ¶
func (c *ChainSpanner) CommitSpan(ctx context.Context, heimdallSpan HeimdallSpan, state *state.StateDB, header *types.Header, chainContext core.ChainContext) error
func (*ChainSpanner) GetCurrentSpan ¶
GetCurrentSpan get current span from contract
type HeimdallSpan ¶
type HeimdallSpan struct { Span ValidatorSet valset.ValidatorSet `json:"validator_set" yaml:"validator_set"` SelectedProducers []valset.Validator `json:"selected_producers" yaml:"selected_producers"` ChainID string `json:"bor_chain_id" yaml:"bor_chain_id"` }
HeimdallSpan represents span from heimdall APIs
Click to show internal directories.
Click to hide internal directories.