Versions in this module Expand all Collapse all v1 v1.0.4 Dec 2, 2019 v1.0.3 Nov 27, 2019 Changes in this version + const CurveType + const Decimal + const Symbol + func NewSimpleAccount2(accountID string, sequence int64) txnbuild.SimpleAccount + type AddrBalance struct + Address string + Balance string + Index int + TokenBalance string + func NewAddrAssetsBalance(b *openwallet.TokenBalance) *AddrBalance + func NewAddrBalance(b *openwallet.Balance) *AddrBalance + func (this *AddrBalance) GetAddress() string + func (this *AddrBalance) ValidTokenBalance() bool + type AddrBalanceInf interface + GetAddress func() string + SetTokenBalance func(b *big.Int) + ValidTokenBalance func() bool + type AddressDecoder struct + func NewAddressDecoder(wm *WalletManager) *AddressDecoder + func (decoder *AddressDecoder) PrivateKeyToWIF(priv []byte, isTestnet bool) (string, error) + func (decoder *AddressDecoder) PublicKeyToAddress(pub []byte, isTestnet bool) (string, error) + func (decoder *AddressDecoder) RedeemScriptToAddress(pubs [][]byte, required uint64, isTestnet bool) (string, error) + func (decoder *AddressDecoder) WIFToPrivateKey(wif string, isTestnet bool) ([]byte, error) + type Block struct + Hash string + Height uint64 + PrevBlockHash string + Time int64 + Transactions []string + TransactionsCnt uint64 + func NewBlock(block hProtocol.Ledger) *Block + func (b *Block) BlockHeader(symbol string) *openwallet.BlockHeader + type Client struct + BaseURL string + Debug bool + func (c *Client) Get(path string, queryparams []interface{}) (*gjson.Result, error) + type ExtractResult struct + BlockHeight uint64 + Success bool + TxID string + type SaveResult struct + BlockHeight uint64 + Success bool + TxID string + type Transaction struct + BlockHash string + BlockHeight uint64 + BlockTime int64 + Fee uint64 + From string + GenesisID string + Note []byte + Payment *models.PaymentTransactionType + TxID string + Type string + func NewTransaction(tx models.Transaction) *Transaction + type TransactionDecoder struct + func NewTransactionDecoder(wm *WalletManager) *TransactionDecoder + func (decoder *TransactionDecoder) CreateAssetsSummaryRawTransaction(wrapper openwallet.WalletDAI, sumRawTx *openwallet.SummaryRawTransaction) ([]*openwallet.RawTransaction, error) + func (decoder *TransactionDecoder) CreateRawAssetsTransaction(wrapper openwallet.WalletDAI, rawTx *openwallet.RawTransaction) error + func (decoder *TransactionDecoder) CreateRawSimpleTransaction(wrapper openwallet.WalletDAI, rawTx *openwallet.RawTransaction) error + func (decoder *TransactionDecoder) CreateRawTransaction(wrapper openwallet.WalletDAI, rawTx *openwallet.RawTransaction) error + func (decoder *TransactionDecoder) CreateSimpleSummaryRawTransaction(wrapper openwallet.WalletDAI, sumRawTx *openwallet.SummaryRawTransaction) ([]*openwallet.RawTransaction, error) + func (decoder *TransactionDecoder) CreateSummaryRawTransaction(wrapper openwallet.WalletDAI, sumRawTx *openwallet.SummaryRawTransaction) ([]*openwallet.RawTransaction, error) + func (decoder *TransactionDecoder) CreateSummaryRawTransactionWithError(wrapper openwallet.WalletDAI, sumRawTx *openwallet.SummaryRawTransaction) ([]*openwallet.RawTransactionWithError, error) + func (decoder *TransactionDecoder) GetRawTransactionFeeRate() (feeRate string, unit string, err error) + func (decoder *TransactionDecoder) SignRawTransaction(wrapper openwallet.WalletDAI, rawTx *openwallet.RawTransaction) error + func (decoder *TransactionDecoder) SubmitRawTransaction(wrapper openwallet.WalletDAI, rawTx *openwallet.RawTransaction) (*openwallet.Transaction, error) + func (decoder *TransactionDecoder) VerifyRawTransaction(wrapper openwallet.WalletDAI, rawTx *openwallet.RawTransaction) error + type TriamBlockScanner struct + CurrentBlockHeight uint64 + RescanLastBlockCount uint64 + func NewTriamBlockScanner(wm *WalletManager) *TriamBlockScanner + func (bs *TriamBlockScanner) AccountExists(account string) bool + func (bs *TriamBlockScanner) BatchExtractTransaction(blockHeight uint64, blockHash string, blockTime int64) error + func (bs *TriamBlockScanner) ExtractTransaction(blockHeight uint64, blockHash string, tx horizon.Transaction, ...) ExtractResult + func (bs *TriamBlockScanner) ExtractTransactionData(txid string, scanAddressFunc openwallet.BlockScanTargetFunc) (map[string][]*openwallet.TxExtractData, error) + func (bs *TriamBlockScanner) GetAssetBalance(accountId, assetsCode, issuerAccountId string) (string, error) + func (bs *TriamBlockScanner) GetBalanceByAddress(address ...string) ([]*openwallet.Balance, error) + func (bs *TriamBlockScanner) GetBlockByHeight(height uint64) (*Block, error) + func (bs *TriamBlockScanner) GetBlockHeight() (uint64, error) + func (bs *TriamBlockScanner) GetCurrentBlock() (*Block, error) + func (bs *TriamBlockScanner) GetCurrentBlockHeader() (*openwallet.BlockHeader, error) + func (bs *TriamBlockScanner) GetGlobalMaxBlockHeight() uint64 + func (bs *TriamBlockScanner) GetNativeAssetBalance(accountId string) (string, error) + func (bs *TriamBlockScanner) GetOperationsByBlock(blockHeight uint64) ([]operations.Payment, int, error) + func (bs *TriamBlockScanner) GetPayOperationByTx(txHash string) ([]operations.Payment, int, error) + func (bs *TriamBlockScanner) GetScannedBlockHeader() (*openwallet.BlockHeader, error) + func (bs *TriamBlockScanner) GetScannedBlockHeight() uint64 + func (bs *TriamBlockScanner) GetTransaction(hash string) (*Transaction, error) + func (bs *TriamBlockScanner) GetTransactionByBlock(blockHeight uint64) ([]horizon.Transaction, error) + func (bs *TriamBlockScanner) InitExtractResult(payment operations.Payment, feePayed string, memo string, blockHeight uint64, ...) + func (bs *TriamBlockScanner) RescanFailedRecord() + func (bs *TriamBlockScanner) SaveUnscanRecord(record *UnscanRecord) error + func (bs *TriamBlockScanner) ScanBlock(height uint64) error + func (bs *TriamBlockScanner) ScanBlockTask() + func (bs *TriamBlockScanner) SetRescanBlockHeight(height uint64) error + type UnscanRecord struct + BlockHeight uint64 + ID string + Reason string + TxID string + func NewUnscanRecord(height uint64, txID, reason string) *UnscanRecord + type WalletConfig struct + AddressRetainAmount string + BlockchainFile string + CurveType uint32 + Decimal int32 + DefaultConfig string + FixFees string + Network string + ServerAPI string + Symbol string + func NewConfig(symbol string) *WalletConfig + type WalletManager struct + Blockscanner *TriamBlockScanner + Config *WalletConfig + ContractDecoder openwallet.SmartContractDecoder + Decoder openwallet.AddressDecoder + Log *log.OWLogger + TxDecoder openwallet.TransactionDecoder + func NewWalletManager() *WalletManager + func (wm *WalletManager) BalanceModelType() openwallet.BalanceModelType + func (wm *WalletManager) CurveType() uint32 + func (wm *WalletManager) Decimal() int32 + func (wm *WalletManager) DeleteUnscanRecord(height uint64) error + func (wm *WalletManager) DeleteUnscanRecordNotFindTX() error + func (wm *WalletManager) FullName() string + func (wm *WalletManager) GetAddressDecode() openwallet.AddressDecoder + func (wm *WalletManager) GetAssetsLogger() *log.OWLogger + func (wm *WalletManager) GetBlockScanner() openwallet.BlockScanner + func (wm *WalletManager) GetLocalBlock(height uint64) (*Block, error) + func (wm *WalletManager) GetLocalNewBlock() (uint64, string) + func (wm *WalletManager) GetSmartContractDecoder() openwallet.SmartContractDecoder + func (wm *WalletManager) GetTransactionDecoder() openwallet.TransactionDecoder + func (wm *WalletManager) GetUnscanRecords() ([]*UnscanRecord, error) + func (wm *WalletManager) InitAssetsConfig() (config.Configer, error) + func (wm *WalletManager) LoadAssetsConfig(c config.Configer) error + func (wm *WalletManager) SaveLocalBlock(block *Block) + func (wm *WalletManager) SaveLocalNewBlock(blockHeight uint64, blockHash string) + func (wm *WalletManager) Symbol() string