Documentation ¶
Index ¶
- type Wallet
- func (w *Wallet) AccAddress() string
- func (w *Wallet) BroadcastTxAsync(data *types.TransactionData) (*sdk.TxResponse, error)
- func (w *Wallet) BroadcastTxCommit(data *types.TransactionData) (*sdk.TxResponse, error)
- func (w *Wallet) BroadcastTxSync(data *types.TransactionData) (*sdk.TxResponse, error)
- func (w *Wallet) BuildTx(data *types.TransactionData) (sdkclient.TxBuilder, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Wallet ¶
type Wallet struct { TxConfig sdkclient.TxConfig Client *client.Client // contains filtered or unexported fields }
Wallet represents a Cosmos wallet that should be used to create and send transactions to the chain
func NewWallet ¶
func NewWallet(accountCfg *types.AccountConfig, client *client.Client, txConfig sdkclient.TxConfig) (*Wallet, error)
NewWallet allows to build a new Wallet instance
func (*Wallet) AccAddress ¶
AccAddress returns the address of the account that is going to be used to sign the transactions
func (*Wallet) BroadcastTxAsync ¶
func (w *Wallet) BroadcastTxAsync(data *types.TransactionData) (*sdk.TxResponse, error)
BroadcastTxAsync creates and signs a transaction with the provided messages and fees, then broadcasts it using the async method
func (*Wallet) BroadcastTxCommit ¶
func (w *Wallet) BroadcastTxCommit(data *types.TransactionData) (*sdk.TxResponse, error)
BroadcastTxCommit creates and signs a transaction with the provided messages and fees, then broadcasts it using the commit method
func (*Wallet) BroadcastTxSync ¶
func (w *Wallet) BroadcastTxSync(data *types.TransactionData) (*sdk.TxResponse, error)
BroadcastTxSync creates and signs a transaction with the provided messages and fees, then broadcasts it using the sync method
Click to show internal directories.
Click to hide internal directories.