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

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

/**
 * 关系类型
 *
 * @author  邓婷婷
 */
@ApiModel(description = "关系类型实体类")
@Table(name = "graphtype.relation_type")
open class RelationType : RBaseInfo() {

    /** 关系类型id */
    @ApiModelProperty(value = "关系类型id")
    @Id
    @Column(name = "id")
    @JSONField(name = "RelationTypeId")
    var relationTypeId: String? = null


    /** 关系类型名称 */
    @ApiModelProperty(value = "关系类型名称")
    @Column(name = "name")
    @JSONField(name = "RelationTypeName")
    var relationTypeName: String? = null

    /** 关系类型编码 */
    @ApiModelProperty(value = "关系类型编码")
    @Column(name = "code")
    @JSONField(name = "RelationTypeCode")
    var relationTypeCode: String? = null

    /** 图类型编码 */
    @ApiModelProperty(value = "图类型编码")
    @Column(name = "graphic_id")
    @JSONField(name = "GraphicId")
    var graphicId: String? = null

    /** 说明 */
    @ApiModelProperty(value = "说明")
    @Column(name = "note")
    @JSONField(name = "Note")
    var note: String? = null

    /** 连接对象 */
    @ApiModelProperty(value = "连接对象")
    @Column(name = "conne_object")
    @JSONField(name = "ConneObject")
    var conneObject: String? = null

    /** 是否需要配置源末端 */
    @ApiModelProperty(value = "是否需要配置源末端")
    @Column(name = "is_source")
    @JSONField(name = "IsSource")
    var isSource: Boolean? = null

    /** 是否自动计算类型 */
    @ApiModelProperty(value = "是否自动计算类型")
    @Column(name = "is_automatic")
    @JSONField(name = "IsAutomatic")
    var isAutomatic: Boolean? = null

    /** 手动计算类型 1 禁用  2提示引导 3手动维护 */
    @ApiModelProperty(value = "手动计算类型 1 禁用  2提示引导 3手动维护")
    @Column(name = "manual")
    @JSONField(name = "Manual")
    var manual: Int? = null

    /** 提示信息 */
    @ApiModelProperty(value = "提示信息")
    @Column(name = "prompting")
    @JSONField(name = "Prompting")
    var prompting: String? = null

    /** 关系表名 */
    @ApiModelProperty(value = "关系表名")
    @Column(name = "table_name")
    @JSONField(name = "TableName")
    var tableName: String? = null


    /** 关系是否双向 */
    @ApiModelProperty(value = "关系是否双向")
    @Column(name = "is_thorough")
    @JSONField(name = "IsThorough")
    var isThorough: Boolean? = null

    /** 关系类型，数据中心用。 */
    @ApiModelProperty(value = "关系类型，数据中心用。")
    @Column(name = "relation_type")
    @JSONField(name = "RelationType")
    var relationType: String? = null

    /** 业务空间类型 */
    @ApiModelProperty(value = "业务空间类型")
    @Column(name = "zone_type")
    @JSONField(name = "ZoneType")
    var zoneType: String? = null

    /** 手动计算查询函数 */
    @ApiModelProperty(value = "手动计算查询函数")
    @Column(name = "manual_query")
    @JSONField(name = "ManualQuery")
    var manualQuery: String? = null

    /** 手动计算主对象类型 */
    @ApiModelProperty(value = "手动计算主对象类型")
    @Column(name = "main_type")
    @JSONField(name = "MainType")
    var mainType: String? = null

    /** 手动计算从对象类型 */
    @ApiModelProperty(value = "手动计算从对象类型")
    @Column(name = "from_type")
    @JSONField(name = "FromType")
    var fromType: String? = null

    /** 手动计算添加关系 */
    @ApiModelProperty(value = "手动计算添加关系")
    @Column(name = "add_rel")
    @JSONField(name = "AddRel")
    var addRel: String? = null

    /** 手动计算删除关系 */
    @ApiModelProperty(value = "手动计算删除关系")
    @Column(name = "del_rel")
    @JSONField(name = "DelRel")
    var delRel: String? = null

    /** 手动计算关系类型 */
    @ApiModelProperty(value = "手动计算关系类型")
    @Column(name = "rel_manual_type")
    @JSONField(name = "RelManualType")
    var relManualType: String? = null

    /** 主对象类型 */
    @ApiModelProperty(value = "主对象类型")
    @Column(name = "main_object")
    @JSONField(name = "MainObject")
    var mainObject: String? = null

    /** 从对象类型 */
    @ApiModelProperty(value = "从对象类型")
    @Column(name = "from_object")
    @JSONField(name = "FromObject")
    var fromObject: String? = null

    /** 机电系统类型 */
    @ApiModelProperty(value = "机电系统类型")
    @Column(name = "mep_system_type")
    @JSONField(name = "MepSystemType")
    var mepSystemType: ArrayList<String>? = null

} // Class RelationType