public class TransactionStorage extends Object
| Constructor and Description |
|---|
TransactionStorage(WalletTransactionDAO walletTransactionDAO) |
| Modifier and Type | Method and Description |
|---|---|
long |
countPendingTransactionAsSender(long networkId,
String fromAddress) |
long |
countPendingTransactionSent(long networkId,
String fromAddress) |
double |
countReceivedContractAmount(String contractAddress,
String address,
ZonedDateTime startDate,
ZonedDateTime endDate) |
double |
countSentContractAmount(String contractAddress,
String address,
ZonedDateTime startDate,
ZonedDateTime endDate) |
List<org.exoplatform.wallet.model.transaction.TransactionDetail> |
getContractTransactions(String contractAddress,
String contractMethodName,
int limit) |
long |
getMaxUsedNonce(long networkId,
String fromAddress) |
List<org.exoplatform.wallet.model.transaction.TransactionDetail> |
getPendingTransaction(long networkId) |
org.exoplatform.wallet.model.transaction.TransactionDetail |
getTransactionByHash(String hash)
Retrieve a
TransactionDetail identified by its blockchain hash |
List<org.exoplatform.wallet.model.transaction.TransactionDetail> |
getTransactions(long networkId,
int limit) |
List<org.exoplatform.wallet.model.transaction.TransactionDetail> |
getTransactionsToSend(long networkId) |
List<org.exoplatform.wallet.model.transaction.TransactionDetail> |
getWalletTransactions(long networkId,
String address,
String contractAddress,
String contractMethodName,
String hash,
int limit,
boolean pending,
boolean administration) |
void |
saveTransactionDetail(org.exoplatform.wallet.model.transaction.TransactionDetail transactionDetail)
Saves a decoded transaction detail in internal database
|
public TransactionStorage(WalletTransactionDAO walletTransactionDAO)
public List<org.exoplatform.wallet.model.transaction.TransactionDetail> getPendingTransaction(long networkId)
networkId - blockchain network idList of TransactionDetail marked as pending in
internal databasepublic List<org.exoplatform.wallet.model.transaction.TransactionDetail> getTransactionsToSend(long networkId)
networkId - blockchain network idList of TransactionDetail not yet sent on
blockchainpublic long getMaxUsedNonce(long networkId,
String fromAddress)
networkId - blockchain network idfromAddress - wallet addresspublic List<org.exoplatform.wallet.model.transaction.TransactionDetail> getContractTransactions(String contractAddress, String contractMethodName, int limit)
contractAddress - filter transactions by a contract addresscontractMethodName - filter transactions by a contract methodlimit - size limit of transactions to retrieveList of TransactionDetail with corresponding filter
entriespublic List<org.exoplatform.wallet.model.transaction.TransactionDetail> getTransactions(long networkId, int limit)
networkId - blockchain network idlimit - size limit of transactions to retrieveList of TransactionDetail for selected blockchain
network idpublic List<org.exoplatform.wallet.model.transaction.TransactionDetail> getWalletTransactions(long networkId, String address, String contractAddress, String contractMethodName, String hash, int limit, boolean pending, boolean administration)
networkId - blockchain network idaddress - wallet addresscontractAddress - filter transactions by a contract addresscontractMethodName - filter transactions by a contract methodhash - retrieve include in the list of transactions this hash even if
the limit is reachedlimit - size limit of transactions to retrievepending - whether include pending or notadministration - whether include administration transactions or notList of TransactionDetail with corresponding filter
entriespublic void saveTransactionDetail(org.exoplatform.wallet.model.transaction.TransactionDetail transactionDetail)
transactionDetail - decoded transaction detailpublic org.exoplatform.wallet.model.transaction.TransactionDetail getTransactionByHash(String hash)
TransactionDetail identified by its blockchain hashhash - blockchain transaction hashTransactionDetailpublic long countPendingTransactionSent(long networkId,
String fromAddress)
networkId - blockchain network idfromAddress - transaction sender addresspublic long countPendingTransactionAsSender(long networkId,
String fromAddress)
networkId - blockchain network idfromAddress - transaction sender addresspublic double countReceivedContractAmount(String contractAddress, String address, ZonedDateTime startDate, ZonedDateTime endDate)
contractAddress - blockchain contract addressaddress - wallet addressstartDate - start date of selected periodendDate - end date of selected periodpublic double countSentContractAmount(String contractAddress, String address, ZonedDateTime startDate, ZonedDateTime endDate)
contractAddress - blockchain contract addressaddress - wallet addressstartDate - start date of selected periodendDate - end date of selected periodCopyright © 2003–2020 eXo Platform SAS. All rights reserved.