Versions in this module Expand all Collapse all v1 v1.0.0 May 26, 2022 Changes in this version + const GlobalTxIndexPrefix + const MaxUnconfirmedTxDuration + const SINGLE + const TxIndexPrefix + const TxPrefix + const UnconfirmedTxCheckPeriod + const UnconfirmedTxPrefix + var ErrInvalidAcctID = errors.New("invalid account id") + var ErrRecoveryBusy = errors.New("another recovery in progress") + type AccountBalance struct + AccountID string + Alias string + Amount uint64 + AssetAlias string + AssetDefinition map[string]interface{} + AssetID string + type AccountVotes struct + AccountID string + Alias string + TotalVoteNumber uint64 + VoteDetails []voteDetail + type SortByTimestamp []*query.AnnotatedTx + func (a SortByTimestamp) Len() int + func (a SortByTimestamp) Less(i, j int) bool + func (a SortByTimestamp) Swap(i, j int) + type StatusInfo struct + BestHash bc.Hash + BestHeight uint64 + Version uint + WorkHash bc.Hash + WorkHeight uint64 + type Summary struct + AccountAlias string + AccountID string + Amount uint64 + Arbitrary chainjson.HexBytes + AssetAlias string + AssetID bc.AssetID + Type string + type TxSummary struct + ID bc.Hash + Inputs []Summary + Outputs []Summary + Timestamp uint64 + type Wallet struct + AccountMgr *account.Manager + AssetReg *asset.Registry + ContractReg *contract.Registry + DB dbm.DB + Hsm *pseudohsm.HSM + RecoveryMgr *recoveryManager + TxIndexFlag bool + func NewWallet(walletDB dbm.DB, account *account.Manager, asset *asset.Registry, ...) (*Wallet, error) + func (w *Wallet) AddUnconfirmedTx(txD *protocol.TxDesc) + func (w *Wallet) AttachBlock(block *types.Block) error + func (w *Wallet) BuildAnnotatedInput(tx *types.Tx, i uint32) *query.AnnotatedInput + func (w *Wallet) BuildAnnotatedOutput(tx *types.Tx, idx int) *query.AnnotatedOutput + func (w *Wallet) DeleteAccount(accountID string) (err error) + func (w *Wallet) DetachBlock(block *types.Block) error + func (w *Wallet) GetAccountBalances(accountID string, id string) ([]AccountBalance, error) + func (w *Wallet) GetAccountUtxos(accountID string, id string, unconfirmed, isSmartContract, vote bool) []*account.UTXO + func (w *Wallet) GetAccountVotes(accountID string, id string) ([]AccountVotes, error) + func (w *Wallet) GetTransactionByTxID(txID string) (*query.AnnotatedTx, error) + func (w *Wallet) GetTransactions(accountID string) ([]*query.AnnotatedTx, error) + func (w *Wallet) GetTransactionsSummary(transactions []*query.AnnotatedTx) []TxSummary + func (w *Wallet) GetUnconfirmedTxByTxID(txID string) (*query.AnnotatedTx, error) + func (w *Wallet) GetUnconfirmedTxs(accountID string) ([]*query.AnnotatedTx, error) + func (w *Wallet) GetWalletStatusInfo() StatusInfo + func (w *Wallet) RemoveUnconfirmedTx(txD *protocol.TxDesc) + func (w *Wallet) RescanBlocks() + func (w *Wallet) UpdateAccountAlias(accountID string, newAlias string) (err error)