client

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2018 License: LGPL-3.0 Imports: 15 Imported by: 0

Documentation

Overview

Copyright (C) 2018 go-dappley authors

This file is part of the go-dappley library.

the go-dappley library is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

the go-dappley library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with the go-dappley library. If not, see <http://www.gnu.org/licenses/>.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Exists added in v0.1.2

func Exists(path string) bool

func GetWalletFilePath added in v0.1.2

func GetWalletFilePath() string

func RemoveWalletFile added in v0.1.2

func RemoveWalletFile()

Types

type Wallet

type Wallet struct {
	Key       *core.KeyPair
	Addresses []core.Address
}

func NewWallet

func NewWallet() *Wallet

func (*Wallet) ContainAddress

func (w *Wallet) ContainAddress(address core.Address) bool

func (*Wallet) GetAddress

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

func (*Wallet) GetAddresses

func (w *Wallet) GetAddresses() []core.Address

func (*Wallet) GetKeyPair

func (w *Wallet) GetKeyPair() *core.KeyPair

type WalletData added in v0.1.2

type WalletData struct {
	Wallets    []*Wallet
	PassPhrase []byte
	Locked     bool
}

type WalletManager added in v0.1.2

type WalletManager struct {
	Wallets []*Wallet

	PassPhrase []byte

	Locked bool
	// contains filtered or unexported fields
}

func NewWalletManager added in v0.1.2

func NewWalletManager(fileLoader storage.FileStorage) *WalletManager

func (*WalletManager) AddWallet added in v0.1.2

func (wm *WalletManager) AddWallet(wallet *Wallet)

func (*WalletManager) GetAddresses added in v0.1.2

func (wm *WalletManager) GetAddresses() []core.Address

func (*WalletManager) GetAddressesWithPassphrase added in v0.1.2

func (wm *WalletManager) GetAddressesWithPassphrase(password string) ([]string, error)

func (*WalletManager) GetKeyPairByAddress added in v0.1.2

func (wm *WalletManager) GetKeyPairByAddress(address core.Address) *core.KeyPair

func (*WalletManager) GetWalletByAddress added in v0.1.2

func (wm *WalletManager) GetWalletByAddress(address core.Address) *Wallet

func (*WalletManager) GetWalletByAddressWithPassphrase added in v0.1.2

func (wm *WalletManager) GetWalletByAddressWithPassphrase(address core.Address, password string) (*Wallet, error)

func (*WalletManager) IsFileEmpty added in v0.1.2

func (wm *WalletManager) IsFileEmpty() (bool, error)

func (*WalletManager) LoadFromFile added in v0.1.2

func (wm *WalletManager) LoadFromFile() error

func (*WalletManager) NewTimer added in v0.1.2

func (wm *WalletManager) NewTimer(timeout time.Duration)

func (*WalletManager) SaveWalletToFile added in v0.1.2

func (wm *WalletManager) SaveWalletToFile()

SaveToFile saves Wallets to a file

func (*WalletManager) SetUnlockTimer added in v0.1.2

func (wm *WalletManager) SetUnlockTimer(timeout time.Duration)

func (*WalletManager) UnlockExpire added in v0.1.2

func (wm *WalletManager) UnlockExpire()

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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