/* * (non-Javadoc) * * @see bl.blService.accountblService.AccountBLManageService#getAccountVOs() */ public List<AccountVO> getAccountVOs() { try { AccountDataService accountDataService = CacheHelper.getAccountDataService(); ArrayList<AccountPO> po = accountDataService.getAccountPOs(); ArrayList<AccountVO> vo = new ArrayList<AccountVO>(po.size()); for (int i = 0; i < po.size(); i++) { AccountPO each = po.get(i); AccountVO temp = (AccountVO) vopoFactory.transPOtoVO(each); vo.add(temp); } return vo; } catch (RemoteException e) { Reconnect.ReConnectFactory(); return null; } }
/* (non-Javadoc) * @see bl.blService.accountblService.AccountBLManageService#fuzzySearch(java.lang.String) */ @Override public List<AccountVO> fuzzySearch(String key) { AccountDataService accountDataService = CacheHelper.getAccountDataService(); try { ArrayList<AccountPO> pos = accountDataService.getAccountPOs(); List<AccountVO> ans = ((List<AccountVO>) vopoFactory.transPOtoVO(pos)) .stream() .filter( acc -> { return acc.fuzzyCheck(key); }) .collect(Collectors.toList()); return ans; } catch (RemoteException e) { Reconnect.ReConnectFactory(); return null; } }