Package money.zumo.zumokit
Interface Wallet
-
- All Known Implementing Classes:
Wallet.CppProxy
public interface Wallet
User wallet provides methods for transfer and exchange of fiat and cryptocurrency funds. Sending a transaction or making an exchange is a two step process. First a transaction or exchange has to be composed via one of the compose methods, thenComposedTransaction
orComposedExchange
can be submitted.User wallet instance can be obtained by creating, unlocking or recovering user wallet via
User
instance.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
Wallet.CppProxy
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
composeEthTransaction(java.lang.String fromAccountId, java.math.BigDecimal gasPrice, int gasLimit, java.lang.String destination, java.math.BigDecimal amount, java.lang.String data, java.lang.Integer nonce, boolean sendMax, ComposeTransactionCallback callback)
Compose Ethereum transaction.void
composeTransaction(java.lang.String fromAccountId, java.lang.String changeAccountId, java.lang.String destination, java.math.BigDecimal amount, java.math.BigDecimal feeRate, boolean sendMax, ComposeTransactionCallback callback)
Compose BTC or BSV transaction.
-
-
-
Method Detail
-
composeTransaction
void composeTransaction(java.lang.String fromAccountId, java.lang.String changeAccountId, java.lang.String destination, java.math.BigDecimal amount, java.math.BigDecimal feeRate, boolean sendMax, ComposeTransactionCallback callback)
Compose BTC or BSV transaction. Refer to Send Transactions guide for usage details.On success
ComposedTransaction
is returned via callback.- Parameters:
fromAccountId
-Account
identifierchangeAccountId
- changeAccount
identifier, which can be the same as fromAccountIddestination
- destination wallet addressamount
- amount in BTC or BSVfeeRate
- fee rate in satoshis/bytesendMax
- send maximum possible funds to destinationcallback
- an interface to receive the result or error
-
composeEthTransaction
void composeEthTransaction(java.lang.String fromAccountId, java.math.BigDecimal gasPrice, int gasLimit, java.lang.String destination, java.math.BigDecimal amount, java.lang.String data, java.lang.Integer nonce, boolean sendMax, ComposeTransactionCallback callback)
Compose Ethereum transaction. Refer to Send Transactions guide for usage details.On success
ComposedTransaction
is returned via callback.- Parameters:
fromAccountId
-Account
identifiergasPrice
- gas price in gweigasLimit
- gas limitdestination
- destination wallet addressamount
- amount in ETHdata
- data in string format or nullnonce
- next transaction nonce or nullsendMax
- send maximum possible funds to destinationcallback
- an interface to receive the result or error
-
-