Documentation ¶
Index ¶
- Constants
- type BeaconClient
- func (bc *BeaconClient) GetBlobSidecarsByBlockroot(blockroot []byte) ([]*deneb.BlobSidecar, error)
- func (bc *BeaconClient) GetBlockBodyByBlockroot(blockroot []byte) (*spec.VersionedSignedBeaconBlock, error)
- func (bc *BeaconClient) GetBlockHeaderByBlockroot(blockroot []byte) (*v1.BeaconBlockHeader, error)
- func (bc *BeaconClient) GetBlockHeaderBySlot(slot uint64) (*v1.BeaconBlockHeader, error)
- func (bc *BeaconClient) GetCommitteeDuties(stateRef string, epoch uint64) ([]*v1.BeaconCommittee, error)
- func (bc *BeaconClient) GetEpochAssignments(epoch uint64, dependendRoot []byte) (*EpochAssignments, error)
- func (bc *BeaconClient) GetFinalityCheckpoints() (*v1.Finality, error)
- func (bc *BeaconClient) GetGenesis() (*v1.Genesis, error)
- func (bc *BeaconClient) GetLatestBlockHead() (*v1.BeaconBlockHeader, error)
- func (bc *BeaconClient) GetNodeSyncing() (*v1.SyncState, error)
- func (bc *BeaconClient) GetNodeVersion() (string, error)
- func (bc *BeaconClient) GetProposerDuties(epoch uint64) (*ProposerDuties, error)
- func (bc *BeaconClient) GetStateValidators(stateRef string) (map[phase0.ValidatorIndex]*v1.Validator, error)
- func (bc *BeaconClient) GetSyncCommitteeDuties(stateRef string, epoch uint64) (*v1.SyncCommittee, error)
- func (bc *BeaconClient) Initialize() error
- func (bc *BeaconClient) NewBlockStream(events uint16) *BeaconStream
- type BeaconStream
- type BeaconStreamEvent
- type EpochAssignments
- type ProposerDuties
Constants ¶
View Source
const ( StreamBlockEvent uint16 = 0x01 StreamHeadEvent uint16 = 0x02 StreamFinalizedEvent uint16 = 0x04 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BeaconClient ¶
type BeaconClient struct {
// contains filtered or unexported fields
}
func NewBeaconClient ¶
func NewBeaconClient(endpoint string, name string, headers map[string]string, sshcfg *types.EndpointSshConfig) (*BeaconClient, error)
NewBeaconClient is used to create a new beacon client
func (*BeaconClient) GetBlobSidecarsByBlockroot ¶
func (bc *BeaconClient) GetBlobSidecarsByBlockroot(blockroot []byte) ([]*deneb.BlobSidecar, error)
func (*BeaconClient) GetBlockBodyByBlockroot ¶
func (bc *BeaconClient) GetBlockBodyByBlockroot(blockroot []byte) (*spec.VersionedSignedBeaconBlock, error)
func (*BeaconClient) GetBlockHeaderByBlockroot ¶
func (bc *BeaconClient) GetBlockHeaderByBlockroot(blockroot []byte) (*v1.BeaconBlockHeader, error)
func (*BeaconClient) GetBlockHeaderBySlot ¶
func (bc *BeaconClient) GetBlockHeaderBySlot(slot uint64) (*v1.BeaconBlockHeader, error)
func (*BeaconClient) GetCommitteeDuties ¶
func (bc *BeaconClient) GetCommitteeDuties(stateRef string, epoch uint64) ([]*v1.BeaconCommittee, error)
func (*BeaconClient) GetEpochAssignments ¶
func (bc *BeaconClient) GetEpochAssignments(epoch uint64, dependendRoot []byte) (*EpochAssignments, error)
GetEpochAssignments will get the epoch assignments from Lighthouse RPC api
func (*BeaconClient) GetFinalityCheckpoints ¶
func (bc *BeaconClient) GetFinalityCheckpoints() (*v1.Finality, error)
func (*BeaconClient) GetGenesis ¶
func (bc *BeaconClient) GetGenesis() (*v1.Genesis, error)
func (*BeaconClient) GetLatestBlockHead ¶
func (bc *BeaconClient) GetLatestBlockHead() (*v1.BeaconBlockHeader, error)
func (*BeaconClient) GetNodeSyncing ¶
func (bc *BeaconClient) GetNodeSyncing() (*v1.SyncState, error)
func (*BeaconClient) GetNodeVersion ¶
func (bc *BeaconClient) GetNodeVersion() (string, error)
func (*BeaconClient) GetProposerDuties ¶
func (bc *BeaconClient) GetProposerDuties(epoch uint64) (*ProposerDuties, error)
func (*BeaconClient) GetStateValidators ¶
func (bc *BeaconClient) GetStateValidators(stateRef string) (map[phase0.ValidatorIndex]*v1.Validator, error)
func (*BeaconClient) GetSyncCommitteeDuties ¶
func (bc *BeaconClient) GetSyncCommitteeDuties(stateRef string, epoch uint64) (*v1.SyncCommittee, error)
func (*BeaconClient) Initialize ¶
func (bc *BeaconClient) Initialize() error
func (*BeaconClient) NewBlockStream ¶
func (bc *BeaconClient) NewBlockStream(events uint16) *BeaconStream
type BeaconStream ¶
type BeaconStream struct { ReadyChan chan bool EventChan chan *BeaconStreamEvent // contains filtered or unexported fields }
func (*BeaconStream) Close ¶
func (bs *BeaconStream) Close()
func (*BeaconStream) Start ¶
func (bs *BeaconStream) Start()
type BeaconStreamEvent ¶
type BeaconStreamEvent struct { Event uint16 Data interface{} }
type EpochAssignments ¶
type ProposerDuties ¶
type ProposerDuties struct { DependentRoot phase0.Root `json:"dependent_root"` Data []*v1.ProposerDuty `json:"data"` }
Click to show internal directories.
Click to hide internal directories.