package com.wsm.admin.model;

import com.wsm.common.model.BaseModel;
import org.hibernate.annotations.Where;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import java.io.Serializable;
import java.math.BigDecimal;

@Entity
@Table(name = "tb_device")
@Where(clause = "rec_status='A'")
public class Device extends BaseModel implements Serializable {

    private static final long serialVersionUID = -3685268556334774675L;
    /**
     * 设备id
     */
    @Column(length = 50)
    private String deviceId;
    /**
     * 设备id 16进制码
     */
    @Column(length = 50)
    private String deviceId16Hex;
    /**
     * 设备类型
     */
    @Column(columnDefinition = "enum('YG','JG')")
    private String deviceType;
    /**
     * 经度
     */
    @Column(precision = 10, scale = 7)
    private BigDecimal longitude;
    /**
     * 纬度
     */
    @Column(precision = 10, scale = 7)
    private BigDecimal latitude;
    /**
     * 地址
     */
    private String address;

    public String getDeviceId() {
        return deviceId;
    }

    public void setDeviceId(String deviceId) {
        this.deviceId = deviceId;
    }

    public String getDeviceType() {
        return deviceType;
    }

    public void setDeviceType(String deviceType) {
        this.deviceType = deviceType;
    }

    public BigDecimal getLongitude() {
        return longitude;
    }

    public void setLongitude(BigDecimal longitude) {
        this.longitude = longitude;
    }

    public BigDecimal getLatitude() {
        return latitude;
    }

    public void setLatitude(BigDecimal latitude) {
        this.latitude = latitude;
    }

    public String getDeviceId16Hex() {
        return deviceId16Hex;
    }

    public void setDeviceId16Hex(String deviceId16Hex) {
        this.deviceId16Hex = deviceId16Hex;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }
}
