041866da8f0903d8a6d6bba80332a07e6163ec16.svn-base 1.1 KB
package yxy.timer.dao.impl;

import java.util.List;

import yxy.timer.dao.YxyReadDao;
import yxy.timer.pojo.YxyReadingInfo;

/*
 * 点读DAO实现类
 */
public class YxyReadDaoImpl extends HibernateBaseDAOImpl<YxyReadingInfo, Long> implements YxyReadDao
{
	/**HQL查询*/
	public List<YxyReadingInfo> findByHql(String hql) throws Exception 
	{
		return super.getAll(hql);
	}
	/**批量插入*/
	public void insertReadPi(List<YxyReadingInfo> o) throws Exception {
		super.addPi(o);
	}
	/**HQL查询指定条数据*/
	public List findByHqlNum(String hql) throws Exception 
	{
		return super.findBySet(hql, 1000);
	}
	/**sql查询*/
	public List<Object> findBySql(String sql) throws Exception
	{
		return super.findBySql(sql);
	}
	
	/**sql更新*/
	public void updateSql(String sql) throws Exception{
		super.updateorDelSql(sql);
	}
	
	/**HQL更新*/
	public void updateByHql(String hql)throws Exception
	{
		super.updateorDelByHql(hql);
	}
	/**批量插入*/
	public int insertRead(YxyReadingInfo o)throws Exception{
		return super.add(o);
	}
	
	public int findByHqlCount(String hql)throws Exception{
		return super.count(hql);
	}
}