ethereum

package
v0.0.54 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2024 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type BeaconChain

type BeaconChain struct {
	// contains filtered or unexported fields
}

func NewBeaconChain

func NewBeaconChain(log logrus.FieldLogger, config *Config) (*BeaconChain, error)

func (*BeaconChain) GenesisTime

func (b *BeaconChain) GenesisTime() time.Time

func (*BeaconChain) NetworkName

func (b *BeaconChain) NetworkName() string

func (*BeaconChain) SecondsPerSlot

func (b *BeaconChain) SecondsPerSlot() uint64

func (*BeaconChain) SlotsPerEpoch

func (b *BeaconChain) SlotsPerEpoch() uint64

func (*BeaconChain) Spec

func (b *BeaconChain) Spec() *SpecConfig

func (*BeaconChain) Start

func (b *BeaconChain) Start() error

func (*BeaconChain) Stop

func (b *BeaconChain) Stop() error

func (*BeaconChain) Wallclock

type Client added in v0.0.46

type Client string
const (
	ClientUnknown    Client = "unknown"
	ClientLighthouse Client = "lighthouse"
	ClientNimbus     Client = "nimbus"
	ClientTeku       Client = "teku"
	ClientPrysm      Client = "prysm"
	ClientLodestar   Client = "lodestar"
)

func ClientFromString added in v0.0.46

func ClientFromString(client string) Client

type Config

type Config struct {
	Network NetworkConfig `yaml:"network"`
}

func (*Config) Validate

func (c *Config) Validate() error

type NetworkConfig

type NetworkConfig struct {
	Name string     `yaml:"name"`
	Spec SpecConfig `yaml:"spec"`
}

func (*NetworkConfig) Validate

func (c *NetworkConfig) Validate() error

type SpecConfig

type SpecConfig struct {
	SecondsPerSlot uint64 `yaml:"seconds_per_slot"`
	SlotsPerEpoch  uint64 `yaml:"slots_per_epoch"`
	GenesisTime    uint64 `yaml:"genesis_time"`
}

func (*SpecConfig) Validate

func (c *SpecConfig) Validate() error

Jump to

Keyboard shortcuts

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