public interface BalanceAccountService
| Modifier and Type | Method and Description |
|---|---|
long |
activateAccount(long accountId)
Activates an inactive account.
|
long |
createAccount(Long ownerResourceId,
boolean active)
Creates an active/inactive account.
|
long |
deactivateAccount(long accountId)
Deactivates an active account.
|
BalanceAccount |
findAccountById(long accountId)
Finds an account by its id.
|
BalanceAccount |
findAccountByResourceId(long resourceId)
Finds an account by its resource id.
|
org.everit.commons.selection.LimitedResult<BalanceAccount> |
findAccountsByOwnerResourceId(Long ownerResourceId,
org.everit.commons.selection.Limit limit)
Returns the
LimitedResult of accounts ordered by accountId. |
long[] |
lockAccounts(long... accountIds)
Locks the given accounts to be able to create transfers on them.
|
long activateAccount(long accountId)
accountId - the ID of the account to activate.long createAccount(Long ownerResourceId, boolean active)
ownerResourceId - The resource ID of the owner of the account, if null a new resource will be created.active - To create an active or an inactive account.long deactivateAccount(long accountId)
accountId - The ID of the account to deactivate.BalanceAccount findAccountById(long accountId)
accountId - The id of the account to be found.BalanceAccount or null if there is no matches.BalanceAccount findAccountByResourceId(long resourceId)
resourceId - the resource id of the account to be foundnull if there is no matchesorg.everit.commons.selection.LimitedResult<BalanceAccount> findAccountsByOwnerResourceId(Long ownerResourceId, org.everit.commons.selection.Limit limit)
LimitedResult of accounts ordered by accountId.ownerResourceId - The resource ID of the owner of the interested accounts or null if all accounts are
interested.limit - the limit of the query, cannot be nullLimitedResult of accounts.long[] lockAccounts(long... accountIds)
BalanceTransferService.createInstantTransfer(String, long, long, java.math.BigDecimal, String)BalanceTransferService.createBlockedTransfer(String, long, long, java.math.BigDecimal, String)BalanceTransferService.acceptBlockedTransfer(long)BalanceTransferService.rejectBlockedTransfer(long)Note 1: A transaction must be available (mandatory) while calling this method, otherwise an exception will be thrown!
Note 2: A deadlock could happen if this method is invoked from different places at the same time!
accountIds - the ID of the accounts to lockCopyright © 2011–2014 Everit Kft.. All rights reserved.