Exemple #1
0
 @Override
 @Loggable(value = LogLevel.TRACE)
 public void updateEmail(Account account) throws AccountManagementException {
   try {
     accountService.updateEmail(account);
     CacheManager.clear(CacheKey.ACCOUNTS);
   } catch (AccountServiceException e) {
     throw new AccountManagementException(e.getMessage(), e.getCause());
   }
 }
Exemple #2
0
 @Loggable(value = LogLevel.TRACE)
 public List<Account> getAccounts(User user) throws AccountManagementException {
   List<Account> accountList = getAccountListFromCache();
   if (accountList != null) {
     return accountList;
   } else {
     try {
       accountList = new ArrayList<Account>();
       for (CustAcctMapDAO accountMap : getAccountMap(user)) {
         accountList.add(getAccount(accountMap.getAccountNo()));
       }
       CacheManager.set(CacheKey.ACCOUNTS, accountList);
       return accountList;
     } catch (AccountManagementException e) {
       throw e;
     }
   }
 }
Exemple #3
0
 private List<Account> getAccountListFromCache() {
   return (List<Account>) CacheManager.get(CacheKey.ACCOUNTS);
 }