mock

package
v1.0.0-alpha.15 Latest Latest
Warning

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

Go to latest
Published: Jul 11, 2020 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Wallet

type Wallet struct {
	Files            map[string]map[string][]byte
	AccountPasswords map[string]string
	UnlockAccounts   bool
	// contains filtered or unexported fields
}

Wallet contains an in-memory, simulated wallet implementation.

func (*Wallet) AccountNames

func (m *Wallet) AccountNames() ([]string, error)

AccountNames --

func (*Wallet) AccountsDir

func (m *Wallet) AccountsDir() string

AccountsDir --

func (*Wallet) CanUnlockAccounts

func (m *Wallet) CanUnlockAccounts() bool

CanUnlockAccounts --

func (*Wallet) ReadFileForAccount

func (m *Wallet) ReadFileForAccount(accountName string, fileName string) ([]byte, error)

ReadFileForAccount --

func (*Wallet) ReadPasswordForAccount

func (m *Wallet) ReadPasswordForAccount(accountName string) (string, error)

ReadPasswordForAccount --

func (*Wallet) WriteAccountToDisk

func (m *Wallet) WriteAccountToDisk(ctx context.Context, password string) (string, error)

WriteAccountToDisk --

func (*Wallet) WriteFileForAccount

func (m *Wallet) WriteFileForAccount(
	ctx context.Context,
	accountName string,
	fileName string,
	data []byte,
) error

WriteFileForAccount --

Jump to

Keyboard shortcuts

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