mock

package
v1.8.0 Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(blockRootToSlotMap map[phase0.Root]phase0.Slot) cache.Service

New creates a new mock cache.

Types

type Service

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

Service is a mock.

func (*Service) BlockRootToSlot

func (s *Service) BlockRootToSlot(_ context.Context, root phase0.Root) (phase0.Slot, error)

BlockRootToSlot provides the slot for a given block root.

func (*Service) ExecutionChainHead added in v1.6.0

func (*Service) ExecutionChainHead(_ context.Context) (phase0.Hash32, uint64)

ExecutionChainHead provides the current execution chain head.

func (*Service) SetBlockRootToSlot added in v1.7.0

func (s *Service) SetBlockRootToSlot(root phase0.Root, slot phase0.Slot)

SetBlockRootToSlot sets the block root to slot mapping.

Jump to

Keyboard shortcuts

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