package com.persagy.server.datacenter.models.entities.dict

import com.alibaba.fastjson.annotation.JSONField
import com.persagy.server.datacenter.models.entities.base.BaseInfo
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 = "dict.class_def")
class DClassDef : BaseInfo() {

    /** 编码 */
    @ApiModelProperty(value = "编码")
    @Id
    @Column(name = "id")
    @JSONField(name = "Code")
    var id: String? = null

    /** 名称 */
    @ApiModelProperty(value = "名称")
    @Column(name = "name")
    @JSONField(name = "Name")
    var name: String? = null

    /** 别编码 */
    @ApiModelProperty(value = "别编码")
    @Column(name = "alias_code")
    @JSONField(name = "AliasCode")
    var aliasCode: String? = null

    /** 别名称 */
    @ApiModelProperty(value = "别名称")
    @Column(name = "alias_name")
    @JSONField(name = "AliasName")
    var aliasName: String? = null

    /** 父类指针 */
    @ApiModelProperty(value = "父类指针")
    @Column(name = "parent_code")
    @JSONField(name = "ParentCode")
    var parentCode: String? = null

    /** 标志 1为专业 2为系统 3为设备 4为部件 */
    @ApiModelProperty(value = "标志 1为专业 2为系统 3为设备 4为部件")
    @Column(name = "sign")
    @JSONField(name = "Sign")
    var sign: String? = null

    /** 子集列表 */
    @ApiModelProperty(value = "子集列表")
    @JSONField(name = "ListClassDef")
    var listClassDef:ArrayList<DClassDef>? = null

    /** 对应物理世界对象类型 */
    @ApiModelProperty(value = "对应物理世界对象类型")
    @Column(name = "type_platform")
    @JSONField(name = "TypePlatform")
    var typePlatform: String? = null

}// Class DClassDef