Newer
Older
pgdsc / src / com / szpg / db / dao / PgWsDao.java
package com.szpg.db.dao;

import java.util.List;

import com.szpg.db.data.PgTemphum;

/**
 * 温湿度相关参数读写的数据库接口
 * @author admin
 *
 */
public interface PgWsDao {

	/******** 温湿度监测值 ********/
	public List<PgTemphum> findAllWsdz();
	public PgTemphum findWsdzById(Integer id);
	public PgTemphum findLatestWsdzByDevice(Integer deviceid);
	
	public List<PgTemphum> findWsdzByDevice(Integer deviceid);
	public List<PgTemphum> findWsdzByDeviceAndTm(Integer deviceid, String start, String end);
	
	public double findLastTempByDevice(Integer deviceid);
	public double findLastHumByDevice(Integer deviceid);
	public PgTemphum findLastRecordByDevice(Integer deviceid);
	
	public int addWsdzRecord(PgTemphum wsdz);
	public int addWsdzRecord(float temp, float hum, String tm, int deviceid);
	
	
	/******** 温湿度报警状态 ********/
//	public List<PgTemphumAlm> findAllWsdbj();
//	public PgTemphumAlm findWsdbjById(Integer id);
	
//	public List<PgTemphumAlm> findWsdbjByDevice(Integer deviceid);
//	public List<PgTemphumAlm> findWsdbjByDeviceAndTm(Integer deviceid, String start, String end);
	
//	public int addWsdbjRecord(PgTemphumAlm wsalm);
//	public int addWsdbjRecord(boolean temp, boolean hum, String tm, int deviceid);
}