public class WalletAccountServiceImpl extends Object implements org.exoplatform.wallet.service.WalletAccountService, org.exoplatform.wallet.statistic.ExoWalletStatisticService, org.picocontainer.Startable
| Constructor and Description |
|---|
WalletAccountServiceImpl(org.exoplatform.container.ExoContainer container,
WalletStorage walletAccountStorage,
AddressLabelStorage labelStorage,
org.exoplatform.container.xml.InitParams params) |
| Modifier and Type | Method and Description |
|---|---|
void |
createAdminAccount(String privateKey,
String currentUser) |
boolean |
enableWalletByAddress(String address,
boolean enable,
String currentUser) |
Set<org.exoplatform.wallet.model.WalletAddressLabel> |
getAddressesLabelsVisibleBy(String currentUser) |
String |
getAdminAccountPassword() |
org.exoplatform.wallet.model.Wallet |
getAdminWallet() |
String |
getPrivateKeyByTypeAndId(String type,
String remoteId) |
String |
getPrivateKeyByTypeAndId(String type,
String remoteId,
String currentUser) |
Map<String,Object> |
getStatisticParameters(String operation,
Object result,
Object... methodArgs) |
org.exoplatform.wallet.model.Wallet |
getWalletByAddress(String address) |
org.exoplatform.wallet.model.Wallet |
getWalletByAddress(String address,
String currentUser) |
org.exoplatform.wallet.model.Wallet |
getWalletByIdentityId(long identityId) |
org.exoplatform.wallet.model.Wallet |
getWalletByTypeAndId(String type,
String remoteId) |
org.exoplatform.wallet.model.Wallet |
getWalletByTypeAndId(String type,
String remoteId,
String currentUser) |
long |
getWalletsCount() |
boolean |
isAdminAccountEnabled() |
boolean |
isWalletOwner(org.exoplatform.wallet.model.Wallet wallet,
String currentUser) |
Set<org.exoplatform.wallet.model.Wallet> |
listWallets() |
void |
refreshWalletFromBlockchain(org.exoplatform.wallet.model.Wallet wallet,
org.exoplatform.wallet.model.ContractDetail contractDetail,
Map<String,Set<String>> walletsModifications) |
void |
refreshWalletsFromBlockchain(Map<String,Set<String>> walletsModifications) |
void |
removePrivateKeyByTypeAndId(String type,
String remoteId,
String currentUser) |
void |
removeWalletByAddress(String address,
String currentUser) |
void |
removeWalletByTypeAndId(String type,
String remoteId,
String currentUser) |
void |
retrieveWalletBlockchainState(org.exoplatform.wallet.model.Wallet wallet) |
org.exoplatform.wallet.model.WalletAddressLabel |
saveOrDeleteAddressLabel(org.exoplatform.wallet.model.WalletAddressLabel label,
String currentUser) |
void |
savePrivateKeyByTypeAndId(String type,
String remoteId,
String content,
String currentUser) |
org.exoplatform.wallet.model.Wallet |
saveWallet(org.exoplatform.wallet.model.Wallet wallet,
boolean isNew) |
void |
saveWalletAddress(org.exoplatform.wallet.model.Wallet wallet,
String currentUser) |
org.exoplatform.wallet.model.Wallet |
saveWalletBackupState(String currentUser,
long identityId,
boolean backupState) |
void |
saveWalletBlockchainState(org.exoplatform.wallet.model.Wallet wallet,
String contractAddress) |
void |
setInitializationStatus(String address,
org.exoplatform.wallet.model.WalletInitializationState initializationState) |
void |
setInitializationStatus(String address,
org.exoplatform.wallet.model.WalletInitializationState initializationState,
String currentUser) |
void |
start() |
void |
stop() |
public WalletAccountServiceImpl(org.exoplatform.container.ExoContainer container,
WalletStorage walletAccountStorage,
AddressLabelStorage labelStorage,
org.exoplatform.container.xml.InitParams params)
public void start()
start in interface org.picocontainer.Startablepublic void stop()
stop in interface org.picocontainer.Startablepublic Set<org.exoplatform.wallet.model.Wallet> listWallets()
listWallets in interface org.exoplatform.wallet.service.WalletAccountServicepublic void refreshWalletsFromBlockchain(Map<String,Set<String>> walletsModifications)
refreshWalletsFromBlockchain in interface org.exoplatform.wallet.service.WalletAccountServicepublic void refreshWalletFromBlockchain(org.exoplatform.wallet.model.Wallet wallet,
org.exoplatform.wallet.model.ContractDetail contractDetail,
Map<String,Set<String>> walletsModifications)
refreshWalletFromBlockchain in interface org.exoplatform.wallet.service.WalletAccountServicepublic long getWalletsCount()
getWalletsCount in interface org.exoplatform.wallet.service.WalletAccountServicepublic org.exoplatform.wallet.model.Wallet getWalletByIdentityId(long identityId)
getWalletByIdentityId in interface org.exoplatform.wallet.service.WalletAccountServicepublic void retrieveWalletBlockchainState(org.exoplatform.wallet.model.Wallet wallet)
retrieveWalletBlockchainState in interface org.exoplatform.wallet.service.WalletAccountServicepublic org.exoplatform.wallet.model.Wallet getWalletByTypeAndId(String type, String remoteId, String currentUser)
getWalletByTypeAndId in interface org.exoplatform.wallet.service.WalletAccountServicepublic org.exoplatform.wallet.model.Wallet getWalletByTypeAndId(String type, String remoteId)
getWalletByTypeAndId in interface org.exoplatform.wallet.service.WalletAccountServicepublic org.exoplatform.wallet.model.Wallet getAdminWallet()
getAdminWallet in interface org.exoplatform.wallet.service.WalletAccountServicepublic void savePrivateKeyByTypeAndId(String type, String remoteId, String content, String currentUser) throws IllegalAccessException
savePrivateKeyByTypeAndId in interface org.exoplatform.wallet.service.WalletAccountServiceIllegalAccessExceptionpublic String getPrivateKeyByTypeAndId(String type, String remoteId, String currentUser) throws IllegalAccessException
getPrivateKeyByTypeAndId in interface org.exoplatform.wallet.service.WalletAccountServiceIllegalAccessExceptionpublic String getPrivateKeyByTypeAndId(String type, String remoteId)
getPrivateKeyByTypeAndId in interface org.exoplatform.wallet.service.WalletAccountServicepublic void removePrivateKeyByTypeAndId(String type, String remoteId, String currentUser) throws IllegalAccessException
removePrivateKeyByTypeAndId in interface org.exoplatform.wallet.service.WalletAccountServiceIllegalAccessExceptionpublic org.exoplatform.wallet.model.Wallet getWalletByAddress(String address, String currentUser)
getWalletByAddress in interface org.exoplatform.wallet.service.WalletAccountServicepublic org.exoplatform.wallet.model.Wallet getWalletByAddress(String address)
getWalletByAddress in interface org.exoplatform.wallet.service.WalletAccountServicepublic void createAdminAccount(String privateKey, String currentUser) throws IllegalAccessException
createAdminAccount in interface org.exoplatform.wallet.service.WalletAccountServiceIllegalAccessExceptionpublic void saveWalletBlockchainState(org.exoplatform.wallet.model.Wallet wallet,
String contractAddress)
saveWalletBlockchainState in interface org.exoplatform.wallet.service.WalletAccountServicepublic org.exoplatform.wallet.model.Wallet saveWalletBackupState(String currentUser, long identityId, boolean backupState) throws IllegalAccessException
saveWalletBackupState in interface org.exoplatform.wallet.service.WalletAccountServiceIllegalAccessExceptionpublic void saveWalletAddress(org.exoplatform.wallet.model.Wallet wallet,
String currentUser)
throws IllegalAccessException
saveWalletAddress in interface org.exoplatform.wallet.service.WalletAccountServiceIllegalAccessExceptionpublic org.exoplatform.wallet.model.Wallet saveWallet(org.exoplatform.wallet.model.Wallet wallet,
boolean isNew)
saveWallet in interface org.exoplatform.wallet.service.WalletAccountServicepublic void removeWalletByAddress(String address, String currentUser) throws IllegalAccessException
removeWalletByAddress in interface org.exoplatform.wallet.service.WalletAccountServiceIllegalAccessExceptionpublic void removeWalletByTypeAndId(String type, String remoteId, String currentUser) throws IllegalAccessException
removeWalletByTypeAndId in interface org.exoplatform.wallet.service.WalletAccountServiceIllegalAccessExceptionpublic boolean enableWalletByAddress(String address, boolean enable, String currentUser) throws IllegalAccessException
enableWalletByAddress in interface org.exoplatform.wallet.service.WalletAccountServiceIllegalAccessExceptionpublic void setInitializationStatus(String address, org.exoplatform.wallet.model.WalletInitializationState initializationState, String currentUser) throws IllegalAccessException
setInitializationStatus in interface org.exoplatform.wallet.service.WalletAccountServiceIllegalAccessExceptionpublic void setInitializationStatus(String address, org.exoplatform.wallet.model.WalletInitializationState initializationState)
setInitializationStatus in interface org.exoplatform.wallet.service.WalletAccountServicepublic boolean isWalletOwner(org.exoplatform.wallet.model.Wallet wallet,
String currentUser)
isWalletOwner in interface org.exoplatform.wallet.service.WalletAccountServicepublic org.exoplatform.wallet.model.WalletAddressLabel saveOrDeleteAddressLabel(org.exoplatform.wallet.model.WalletAddressLabel label,
String currentUser)
saveOrDeleteAddressLabel in interface org.exoplatform.wallet.service.WalletAccountServicepublic Set<org.exoplatform.wallet.model.WalletAddressLabel> getAddressesLabelsVisibleBy(String currentUser)
getAddressesLabelsVisibleBy in interface org.exoplatform.wallet.service.WalletAccountServicepublic String getAdminAccountPassword()
getAdminAccountPassword in interface org.exoplatform.wallet.service.WalletAccountServicepublic Map<String,Object> getStatisticParameters(String operation, Object result, Object... methodArgs)
getStatisticParameters in interface org.exoplatform.wallet.statistic.ExoWalletStatisticServicepublic boolean isAdminAccountEnabled()
isAdminAccountEnabled in interface org.exoplatform.wallet.service.WalletAccountServiceCopyright © 2003–2020 eXo Platform SAS. All rights reserved.