standard

package
v0.6.1 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2020 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Parameter

type Parameter interface {
	// contains filtered or unexported methods
}

Parameter is the interface for service parameters.

func WithBeaconBlockSubmitter

func WithBeaconBlockSubmitter(submitter submitter.BeaconBlockSubmitter) Parameter

WithBeaconBlockSubmitter sets the beacon block submitter.

func WithGraffitiProvider

func WithGraffitiProvider(provider graffitiprovider.Service) Parameter

WithGraffitiProvider sets the graffiti provider.

func WithLogLevel

func WithLogLevel(logLevel zerolog.Level) Parameter

WithLogLevel sets the log level for the module.

func WithMonitor

func WithMonitor(monitor metrics.BeaconBlockProposalMonitor) Parameter

WithMonitor sets the monitor for this module.

func WithProposalDataProvider

func WithProposalDataProvider(provider eth2client.BeaconBlockProposalProvider) Parameter

WithProposalDataProvider sets the proposal data provider.

func WithValidatingAccountsProvider

func WithValidatingAccountsProvider(provider accountmanager.ValidatingAccountsProvider) Parameter

WithValidatingAccountsProvider sets the account manager.

type Service

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

Service is a beacon block proposer.

func New

func New(ctx context.Context, params ...Parameter) (*Service, error)

New creates a new beacon block proposer.

func (*Service) Prepare

func (s *Service) Prepare(ctx context.Context, data interface{}) error

Prepare prepares for a beacon block proposal, carrying out activities that can be undertaken before the time the proposal is required.

func (*Service) Propose

func (s *Service) Propose(ctx context.Context, data interface{})

Propose proposes a block.

Jump to

Keyboard shortcuts

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