package com.moral.api.entity;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import java.io.Serializable;
import java.util.Date;
import lombok.Data;
import lombok.EqualsAndHashCode;
/**
 * 
 * 城市aqi实测小时数据表
 * 
 *
 * @author moral
 * @since 2021-09-28
 */
@Data
@EqualsAndHashCode(callSuper = false)
public class CityAqi extends Model {
    private static final long serialVersionUID = 1L;
    /**
     * 城市id
     */
    private Integer cityCode;
    /**
     * 时间
     */
    private Date time;
    /**
     * 数据
     */
    private String value;
    @Override
    protected Serializable pkVal() {
        return null;
    }
    public CityAqi() {
    }
    public CityAqi(CityAqiDaily cityAqiDaily) {
        this.cityCode = cityAqiDaily.getCityCode();
        this.value = cityAqiDaily.getValue();
        this.time = cityAqiDaily.getTime();
    }
    public CityAqi(CityAqiMonthly cityAqiMonthly) {
        this.cityCode = cityAqiMonthly.getCityCode();
        this.value = cityAqiMonthly.getValue();
        this.time = cityAqiMonthly.getTime();
    }
    public CityAqi(CityAqiYearly cityAqiYearly) {
        this.cityCode = cityAqiYearly.getCityCode();
        this.value = cityAqiYearly.getValue();
        this.time = cityAqiYearly.getTime();
    }
}