beaconinterface

package
v0.0.0-...-7a2e46d Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2023 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const NODE_TIMEOUT = 2 * time.Second

Variables

This section is empty.

Functions

This section is empty.

Types

type BeaconClient

type BeaconClient struct {
	Node               beaconClient.BeaconClientInstance
	NodeSpeed          time.Duration
	LastUsedTime       time.Time
	LastResponseStatus int
	SyncStatus         *beaconTypes.SyncStatusData
}

type MultiBeaconClient

type MultiBeaconClient struct {
	Clients []BeaconClient

	BeaconData *beaconData.BeaconData
	// contains filtered or unexported fields
}

func NewMultiBeaconClient

func NewMultiBeaconClient(beaconUrls []string) (*MultiBeaconClient, error)

func (*MultiBeaconClient) Genesis

func (b *MultiBeaconClient) Genesis() (genesisData *beaconTypes.GenesisData, err error)

func (*MultiBeaconClient) GetBlockHeader

func (b *MultiBeaconClient) GetBlockHeader(slot uint64) (blockHeader *beaconTypes.BlockHeaderData, err error)

func (*MultiBeaconClient) GetCurrentBlockHeader

func (b *MultiBeaconClient) GetCurrentBlockHeader() (blockHeader *beaconTypes.BlockHeaderData, err error)

func (*MultiBeaconClient) GetCurrentHead

func (b *MultiBeaconClient) GetCurrentHead() (beaconTypes.HeadEventData, error)

func (*MultiBeaconClient) GetForkVersion

func (b *MultiBeaconClient) GetForkVersion(slot uint64, head bool) (forkName string, forkVersion string, err error)

func (*MultiBeaconClient) GetPayloadAttributesForSlot

func (b *MultiBeaconClient) GetPayloadAttributesForSlot(requestedSlot uint64) (*beaconTypes.PayloadAttributesEventData, error)

func (*MultiBeaconClient) GetSlotProposer

func (b *MultiBeaconClient) GetSlotProposer(requestedSlot uint64) (*beaconTypes.ProposerDutyData, error)

func (*MultiBeaconClient) GetSlotProposerMap

func (b *MultiBeaconClient) GetSlotProposerMap(epoch uint64) (beaconData.SlotProposerMap, error)

func (*MultiBeaconClient) GetValidatorIndex

func (b *MultiBeaconClient) GetValidatorIndex(newValidators []string, validatorIndexes *relayTypes.ValidatorIndexes)

func (*MultiBeaconClient) GetValidatorList

func (b *MultiBeaconClient) GetValidatorList(slot uint64) ([]*beaconTypes.ValidatorData, error)

func (*MultiBeaconClient) GetWithdrawals

func (b *MultiBeaconClient) GetWithdrawals(slot uint64) (withdrawals *beaconTypes.Withdrawals, err error)

func (*MultiBeaconClient) PublishBlock

func (*MultiBeaconClient) Randao

func (b *MultiBeaconClient) Randao(slot uint64) (randao *common.Hash, err error)

func (*MultiBeaconClient) RetrieveValidatorByIndex

func (b *MultiBeaconClient) RetrieveValidatorByIndex(validatorIndex uint64) (*beaconTypes.ValidatorData, error)

func (*MultiBeaconClient) RetrieveValidatorByPubkey

func (b *MultiBeaconClient) RetrieveValidatorByPubkey(validatorPubkey string) (*beaconTypes.ValidatorData, error)

func (*MultiBeaconClient) ReturnAllNodeURLs

func (b *MultiBeaconClient) ReturnAllNodeURLs() []string

func (*MultiBeaconClient) Start

func (b *MultiBeaconClient) Start()

func (*MultiBeaconClient) SubscribeToHeadEvents

func (b *MultiBeaconClient) SubscribeToHeadEvents(ctx context.Context, headChannel chan beaconTypes.HeadEventData)

func (*MultiBeaconClient) SubscribeToPayloadAttributesEvents

func (b *MultiBeaconClient) SubscribeToPayloadAttributesEvents(ctx context.Context, attrsC chan beaconTypes.PayloadAttributesEvent)

func (*MultiBeaconClient) SyncStatus

func (b *MultiBeaconClient) SyncStatus() (*beaconTypes.SyncStatusData, error)

func (*MultiBeaconClient) UpdateForkVersion

func (b *MultiBeaconClient) UpdateForkVersion()

func (*MultiBeaconClient) UpdateKnownValidators

func (b *MultiBeaconClient) UpdateKnownValidators(slot uint64)

func (*MultiBeaconClient) UpdateRandaoMap

func (b *MultiBeaconClient) UpdateRandaoMap(slot uint64)

func (*MultiBeaconClient) UpdateValidatorMap

func (b *MultiBeaconClient) UpdateValidatorMap()

func (*MultiBeaconClient) ValidatorIndexExists

func (b *MultiBeaconClient) ValidatorIndexExists(validatorIndex uint64) bool

func (*MultiBeaconClient) ValidatorPubkeyExists

func (b *MultiBeaconClient) ValidatorPubkeyExists(validatorPubkey string) bool

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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