package com.gkhy.fourierSpecialGasMonitor.entity; import lombok.Data; import javax.persistence.*; import java.time.LocalDateTime; @Entity @Table(name = "summary_stats") @Data public class SummaryStats { @Id @GeneratedValue(strategy = GenerationType.IDENTITY) private Long id; private LocalDateTime time; //温度 private Double tempMin; private Double tempMax; private Double tempAvg; private Double temp; //湿度 private Double humidityMin; private Double humidityMax; private Double humidityAvg; private Double humidity; //风速 private Double windSpeedMin; private Double windSpeedMax; private Double windSpeedAvg; private Double windSpeed; //风向 private Integer windDirectionMin; private Integer windDirectionMax; private Double windDirectionAvg; private int windDirection; //压力 private Double pressureMin; private Double pressureMax; private Double pressureAvg; private Double pressure; public SummaryStats(Double tempMin, Double tempMax, Double tempAvg, Double humidityMin, Double humidityMax, Double humidityAvg, Double windSpeedMin, Double windSpeedMax, Double windSpeedAvg, Integer windDirectionMin, Integer windDirectionMax, Double windDirectionAvg, Double pressureMin, Double pressureMax, Double pressureAvg) { this.tempMin = tempMin; this.tempMax = tempMax; this.tempAvg = tempAvg; this.humidityMin = humidityMin; this.humidityMax = humidityMax; this.humidityAvg = humidityAvg; this.windSpeedMin = windSpeedMin; this.windSpeedMax = windSpeedMax; this.windSpeedAvg = windSpeedAvg; this.windDirectionMin = windDirectionMin; this.windDirectionMax = windDirectionMax; this.windDirectionAvg = windDirectionAvg; this.pressureMin = pressureMin; this.pressureMax = pressureMax; this.pressureAvg = pressureAvg; } public SummaryStats() { } public boolean isEmpty(){ return tempMin == null&&humidityMin==null&&windSpeedMin==null&&pressureMin==null&& windDirectionMin == null; } public Long getId() { return id; } public void setId(Long id) { this.id = id; } public LocalDateTime getTime() { return time; } public void setTime(LocalDateTime time) { this.time = time; } public Double getTempMin() { return tempMin; } public void setTempMin(Double tempMin) { this.tempMin = tempMin; } public Double getTempMax() { return tempMax; } public void setTempMax(Double tempMax) { this.tempMax = tempMax; } public Double getTempAvg() { return tempAvg; } public void setTempAvg(Double tempAvg) { this.tempAvg = tempAvg; } public Double getTemp() { return temp; } public void setTemp(Double temp) { this.temp = temp; } public Double getHumidityMin() { return humidityMin; } public void setHumidityMin(Double humidityMin) { this.humidityMin = humidityMin; } public Double getHumidityMax() { return humidityMax; } public void setHumidityMax(Double humidityMax) { this.humidityMax = humidityMax; } public Double getHumidityAvg() { return humidityAvg; } public void setHumidityAvg(Double humidityAvg) { this.humidityAvg = humidityAvg; } public Double getHumidity() { return humidity; } public void setHumidity(Double humidity) { this.humidity = humidity; } public Double getWindSpeedMin() { return windSpeedMin; } public void setWindSpeedMin(Double windSpeedMin) { this.windSpeedMin = windSpeedMin; } public Double getWindSpeedMax() { return windSpeedMax; } public void setWindSpeedMax(Double windSpeedMax) { this.windSpeedMax = windSpeedMax; } public Double getWindSpeedAvg() { return windSpeedAvg; } public void setWindSpeedAvg(Double windSpeedAvg) { this.windSpeedAvg = windSpeedAvg; } public Double getWindSpeed() { return windSpeed; } public void setWindSpeed(Double windSpeed) { this.windSpeed = windSpeed; } public int getWindDirectionMin() { return windDirectionMin; } public void setWindDirectionMin(int windDirectionMin) { this.windDirectionMin = windDirectionMin; } public int getWindDirectionMax() { return windDirectionMax; } public void setWindDirectionMax(int windDirectionMax) { this.windDirectionMax = windDirectionMax; } public Double getWindDirectionAvg() { return windDirectionAvg; } public void setWindDirectionAvg(Double windDirectionAvg) { this.windDirectionAvg = windDirectionAvg; } public int getWindDirection() { return windDirection; } public void setWindDirection(int windDirection) { this.windDirection = windDirection; } public Double getPressureMin() { return pressureMin; } public void setPressureMin(Double pressureMin) { this.pressureMin = pressureMin; } public Double getPressureMax() { return pressureMax; } public void setPressureMax(Double pressureMax) { this.pressureMax = pressureMax; } public Double getPressureAvg() { return pressureAvg; } public void setPressureAvg(Double pressureAvg) { this.pressureAvg = pressureAvg; } public Double getPressure() { return pressure; } public void setPressure(Double pressure) { this.pressure = pressure; } }