accounts

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2025 License: GPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Account

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

func NewRollupAccount

func NewRollupAccount(privateKeyHex string, onRollup *rollup.Rollup) (*Account, error)

NewRollupAccount creates a new blockchain account

func (*Account) Close

func (ac *Account) Close()

Close closes the blockchain client connection

func (*Account) GetAddress

func (ac *Account) GetAddress() common.Address

GetAddress returns the address derived from the private key

func (*Account) GetBalance

func (ac *Account) GetBalance(ctx context.Context) (*big.Int, error)

GetBalance returns the balance of the account

func (*Account) GetNonce

func (ac *Account) GetNonce(ctx context.Context) (uint64, error)

GetNonce returns the nonce for the next transaction

func (*Account) GetPrivateKey

func (ac *Account) GetPrivateKey() *ecdsa.PrivateKey

func (*Account) GetRollup

func (ac *Account) GetRollup() *rollup.Rollup

GetRollup returns the rollup associated with this account

func (*Account) GetTokensBalance

func (ac *Account) GetTokensBalance(ctx context.Context, contractAddress common.Address, contractABI abi.ABI) (*big.Int, error)

Jump to

Keyboard shortcuts

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