Newer
Older
huludao / src / main / java / com / newfiber / api / pc / model / entity / CameraResource.java
package com.newfiber.api.pc.model.entity;

import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import com.baomidou.mybatisplus.enums.IdType;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * @ClassName CameraResource 摄像头资源实体类
 * @Description TODO
 * @Author 张鸿志
 * @Date 2021年3月4日16:37:00 16:36
 * Version 1.0
 **/
@Data
@TableName("camera_resource")
public class CameraResource implements Serializable{
    @TableId(value = "id",type = IdType.AUTO)
    private Integer id;
    @TableField("index_code")
    private String indexCode;
    @TableField("name")
    private  String name;
    @TableField("region_index_code")
    private String regionIndexCode;
    @TableField("is_top")
    private Integer isTop;
    @TableField("is_show")
    private Integer isShow;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @TableField("create_time")
    private Date createTime;
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @TableField("update_time")
    private Date updateTime;

    @TableField("x")
    private String x;
    @TableField("y")
    private String y;

    @TableField("status")
    private Integer status;
    /** 是否是高点摄像机 */
    @TableField("is_high_spot")
    private Integer isHighSpot;

    @TableField("camera_address")
    private String cameraAddress;


    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        CameraResource that = (CameraResource) o;

        return indexCode != null ? indexCode.equals(that.indexCode) : that.indexCode == null;
    }

    @Override
    public int hashCode() {
        return indexCode != null ? indexCode.hashCode() : 0;
    }
}