zksyncera

package
v0.0.0-...-b194359 Latest Latest
Warning

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

Go to latest
Published: Jul 18, 2024 License: AGPL-3.0 Imports: 25 Imported by: 0

Documentation

Overview

Package zksyncera implements transfer operation on ZkSync Era network.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Auditor

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

func NewAuditor

func NewAuditor(url string) (*Auditor, error)

func (*Auditor) CheckConfirmedTransactionState

func (a *Auditor) CheckConfirmedTransactionState(ctx context.Context, hash string) (pipelinedb.TxState, error)

CheckConfirmedTransactionState checks the state from the confirmation receipt.

func (*Auditor) CheckTransactionState

func (a *Auditor) CheckTransactionState(ctx context.Context, hash string) (pipelinedb.TxState, error)

CheckTransactionState checks the transaction state of any transaction.

type Payer

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

func NewPayer

func NewPayer(
	contractAddress common.Address,
	url string,
	key *ecdsa.PrivateKey,
	chainID int,
	paymasterAddress *common.Address,
	paymasterPayload []byte,
	maxFee *big.Int) (*Payer, error)

func (*Payer) CheckNonceGroup

func (p *Payer) CheckNonceGroup(ctx context.Context, log *zap.Logger, nonceGroup *pipelinedb.NonceGroup, checkOnly bool) (pipelinedb.TxState, []*pipelinedb.TxStatus, error)

func (*Payer) CheckPreconditions

func (p *Payer) CheckPreconditions(ctx context.Context) ([]string, error)

func (*Payer) CreateRawTransaction

func (p *Payer) CreateRawTransaction(ctx context.Context, log *zap.Logger, payouts []*pipelinedb.Payout, nonce uint64, storjPrice decimal.Decimal) (tx payer.Transaction, from common.Address, err error)

func (*Payer) GetTokenBalance

func (p *Payer) GetTokenBalance(ctx context.Context) (*big.Int, error)

func (*Payer) GetTokenDecimals

func (p *Payer) GetTokenDecimals(ctx context.Context) (int32, error)

func (*Payer) NextNonce

func (p *Payer) NextNonce(ctx context.Context) (uint64, error)

func (*Payer) PrintEstimate

func (p *Payer) PrintEstimate(ctx context.Context, remaining int64) error

func (*Payer) SendTransaction

func (p *Payer) SendTransaction(ctx context.Context, log *zap.Logger, tx payer.Transaction) error

func (*Payer) String

func (p *Payer) String() string

Jump to

Keyboard shortcuts

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