📄 cpdaohibernate.java
字号:
package com.longtime.wap.module.business.dao.hibernate;
import java.util.List;
import com.longtime.wap.common.BaseDao;
import com.longtime.wap.model.Cp;
import com.longtime.wap.module.business.dao.CpDao;
/**
* CpDao层代码实现类
*
* @author gengb
* @date Nov 15, 2007
*/
public class CpDaoHibernate extends BaseDao implements CpDao {
/**
* 获取cp列表
*
* @return cp对象列表
*/
public List retrieveCps() {
return this.getHibernateTemplate().find("from Cp order by cpId asc");
}
/**
* 根据cp的Id获取cp对象
*
* @param id
* cp编号
* @return cp对象
*/
public Cp retrieveCpByCpId(Long id) {
return (Cp) this.getHibernateTemplate().get(Cp.class, id);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -