anchortxvalidator

package
v0.20.0 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2024 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AnchorTxValidator

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

AnchorTxValidator is responsible for validating the anchor transaction (TaikoL2.anchor) in each L2 block, which is always the first transaction.

func New

func New(taikoL2Address common.Address, chainID *big.Int, rpc *rpc.Client) (*AnchorTxValidator, error)

New creates a new AnchorTxValidator instance.

func (*AnchorTxValidator) GetAndValidateAnchorTxReceipt

func (v *AnchorTxValidator) GetAndValidateAnchorTxReceipt(
	ctx context.Context,
	tx *types.Transaction,
) (*types.Receipt, error)

GetAndValidateAnchorTxReceipt gets and validates the `TaikoL2.anchor` transaction's receipt.

func (*AnchorTxValidator) ValidateAnchorTx

func (v *AnchorTxValidator) ValidateAnchorTx(tx *types.Transaction) error

ValidateAnchorTx checks whether the given transaction is a valid `TaikoL2.anchor` transaction.

Jump to

Keyboard shortcuts

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