예제 #1
0
  public List<User> getUserByNameAndPassword(String name, String password) {

    String[] params = {"name", "password"};
    Object[] values = {name, password};
    return templateDao.findByQueryWithParams(User.getUserByNameAndPassword, params, values);
  }
예제 #2
0
 public List<User> getUserByName(String name) {
   return templateDao.findByQueryWithParam(User.getUserByName, "name", name);
 }
예제 #3
0
 public void delete(User user) {
   templateDao.delete(user);
 }
예제 #4
0
 public List<User> getAllUsers() {
   return templateDao.findByNamedQuery(User.getAllUsers);
 }
예제 #5
0
 public void save(User user) {
   templateDao.save(user);
 }