wallet

package
v0.0.0-...-24518c4 Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2022 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrIncorrectAccounts error = errors.New("must have exactly one account")

Functions

This section is empty.

Types

type Wallet

type Wallet struct {
	KeyStore *keystore.KeyStore
	Account  accounts.Account
}

func Generate

func Generate(path, password string) (*Wallet, error)

Creates a new wallet

func GenerateFromTerm

func GenerateFromTerm(path string) (*Wallet, error)

Creates a new wallet with a password from stdin and returns it

func Load

func Load(path string) (*Wallet, error)

Loads an existing wallet and unlocks it with a password from stdin

func LoadWithPassword

func LoadWithPassword(path, password string) (*Wallet, error)

Loads an existing wallet and unlocks it with the given password

func (*Wallet) GetAddress

func (w *Wallet) GetAddress() common.Address

Returns the public address of the wallet

Jump to

Keyboard shortcuts

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