@Override public Application findByNameAndUser(User user, String name) throws ServiceException { try { Application application = applicationDAO.findByNameAndUser(user.getId(), name); return application; } catch (PersistenceException e) { logger.error(user.toString(), e); throw new ServiceException(user.toString(), e); } }
@Override public List<Application> findAllByUser(User user) throws ServiceException { try { List<Application> applications = applicationDAO.findAllByUser(user.getId()); logger.debug("ApplicationService : All Applications found "); return applications; } catch (PersistenceException e) { logger.error("Error ApplicationService : error findById Method : " + user); throw new ServiceException(user.toString(), e); } }