statefetcher

package
v1.3.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 9, 2021 License: GPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Fetcher added in v1.3.6

type Fetcher interface {
	State(ctx context.Context, stateId []byte) (iface.BeaconState, error)
}

Fetcher is responsible for retrieving the BeaconState.

type StateProvider added in v1.3.6

type StateProvider struct {
	BeaconDB           db.ReadOnlyDatabase
	ChainInfoFetcher   blockchain.ChainInfoFetcher
	GenesisTimeFetcher blockchain.TimeFetcher
	StateGenService    stategen.StateManager
}

StateProvider is a real implementation of Fetcher.

func (*StateProvider) State added in v1.3.6

func (p *StateProvider) State(ctx context.Context, stateId []byte) (iface.BeaconState, error)

State returns the BeaconState for a given identifier. The identifier can be one of:

  • "head" (canonical head in node's view)
  • "genesis"
  • "finalized"
  • "justified"
  • <slot>
  • <hex encoded stateRoot with 0x prefix>

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL