distributor

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2024 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client interface {
	GetAccount(address string) (*gnoland.GnoAccount, error)
	BroadcastTransaction(tx *std.Tx) error
}

type Distributor

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

Distributor is the process that manages sub-account distributions

func NewDistributor

func NewDistributor(
	cli Client,
) *Distributor

NewDistributor creates a new instance of the distributor

func (*Distributor) Distribute

func (d *Distributor) Distribute(
	distributor crypto.PrivKey,
	accounts []crypto.Address,
	transactions uint64,
	chainID string,
) ([]std.Account, error)

Distribute distributes the funds from the base account (account 0 in the mnemonic) to other subaccounts

Jump to

Keyboard shortcuts

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