package cn.sagacloud.server.datacenter.models.entities.relationship

import cn.sagacloud.server.datacenter.models.entities.base.RBaseInfo
import com.alibaba.fastjson.annotation.JSONField
import com.google.gson.annotations.SerializedName
import io.swagger.annotations.ApiModel
import io.swagger.annotations.ApiModelProperty
import javax.persistence.Column
import javax.persistence.Id
import javax.persistence.Table

/**
 * 设备服务于楼层实体类
 *
 * @author 付国宝
 */
@ApiModel(value = "元空间的邻接关系")
@Table(name = "r_spatial_connection")
class RSpatialConnection : RBaseInfo() {

    /** 空间id */
    @ApiModelProperty(value = "空间id")
    @Column(name = "space_id_one")
    @Id
    @JSONField(name = "SpaceIdOne")
    @SerializedName("SpaceIdOne")
    var spaceIdOne: String? = null

    /** 邻接的空间id */
    @ApiModelProperty(value = "邻接的空间id")
    @Column(name = "space_id_two")
    @Id
    @JSONField(name = "SpaceIdTwo")
    @SerializedName("SpaceIdTwo")
    var spaceIdTwo: String? = null

    /** 位置坐标 */
    @ApiModelProperty(value = "位置坐标")
    @Column(name = "location_one")
    @JSONField(name = "LocationOne")
    @SerializedName("LocationOne")
    var locationOne: String? = null

    /** 邻接的元空间id */
    @ApiModelProperty(value = "邻接的元空间id")
    @Column(name = "location_two")
    @JSONField(name = "LocationTwo")
    @SerializedName("LocationTwo")
    var locationTwo: String? = null

    /** 项目id */
    @ApiModelProperty(value = "项目id")
    @Column(name = "project_id")
    @JSONField(name = "ProjectId")
    @SerializedName("ProjectId")
    var projectId: String? = null

    /** 计算标记 1 为手动 2为自动 */
    @ApiModelProperty(value = "计算标记 1 为手动 2为自动 ")
    @Column(name = "sign")
    @JSONField(name = "Sign")
    @SerializedName("Sign")
    var sign: Int? = null

    /** 图类型id */
    @ApiModelProperty(value = "图类型id")
    @Column(name = "graph_type")
    @JSONField(name = "GraphType")
    @SerializedName("GraphType")
    var graphType: String? = null

    /** 边类型id */
    @ApiModelProperty(value = "边类型id")
    @Column(name = "rel_type")
    @JSONField(name = "RelType")
    @SerializedName("RelType")
    var relType: String? = null

    /** 对象类型 */
    @ApiModelProperty(value = "对象类型")
    @Column(name = "zone_type")
    @JSONField(name = "ZoneType")
    @SerializedName("ZoneType")
    var zoneType: String? = null

    /** 楼层id */
    @ApiModelProperty(value = "楼层id")
    @Column(name = "floor_id")
    @JSONField(name = "FloorId")
    @SerializedName("FloorId")
    var floorId: String? = null

} // Class REqForFl