preimage

package
v1.7.4 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2024 License: MIT Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const MinPreimageSize = 10000

Variables

This section is empty.

Functions

This section is empty.

Types

type Helper

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

func NewHelper

func NewHelper(t *testing.T, opts *bind.TransactOpts, client *ethclient.Client, addr common.Address) *Helper

func (*Helper) UploadLargePreimage

func (h *Helper) UploadLargePreimage(ctx context.Context, dataSize int, modifiers ...InputModifier) types.LargePreimageIdent

UploadLargePreimage inits the preimage upload and uploads the leaves, starting the challenge period. Squeeze is not called by this method as the challenge period has not yet elapsed.

func (*Helper) WaitForChallenged

func (h *Helper) WaitForChallenged(ctx context.Context, ident types.LargePreimageIdent)

type InputModifier

type InputModifier func(startBlock uint64, input *types.InputData)

func WithLastCommitment added in v1.5.1

func WithLastCommitment(value common.Hash) InputModifier

func WithReplacedCommitment

func WithReplacedCommitment(idx uint64, value common.Hash) InputModifier

Jump to

Keyboard shortcuts

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