📄 userdaoimpl.java
字号:
package com.lovo.zengxy.web.dao.hibernate;
import java.util.List;
import com.lovo.zengxy.base.hibernate.BaseDAOImpl;
import com.lovo.zengxy.model.User;
import com.lovo.zengxy.util.BaseDAOException;
import com.lovo.zengxy.web.dao.UserDAO;
public class UserDAOImpl extends BaseDAOImpl implements UserDAO {
public List<User> findUserListPage(int firstResult, int maxResults)
throws BaseDAOException {
String hql = "from User order by id asc";
return super.cutPage(firstResult, maxResults, hql, null);
}
public int getUserTotaleCount() throws BaseDAOException {
return (Integer)super.getByCondition("select count(*) from User", null);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -