package com.xydl.cac.entity;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.*;
import java.util.List;

@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
@Entity
@Table(name = "icd_file")
@ApiModel("ICD文件表")
public class IcdFile {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "id")
    private Integer id;

    @ApiModelProperty(name = "md5")
    @Column(name = "md5")
    private String md5;

    @ApiModelProperty(name = "filename")
    @Column(name = "filename")
    private String filename;

    @ApiModelProperty(name = "xml")
    @Column(name = "xml")
    private String xml;

    @ApiModelProperty(name = "是否服务端")
    @Column(name = "srv")
    private Integer srv;

    @ApiModelProperty(name = "是否启动")
    @Column(name = "start")
    private Integer start;

    @ApiModelProperty(name = "端口")
    @Column(name = "port")
    private Integer port;

    @Transient
    private List<IcdConfigType> configList;
    @Transient
    private List<IcdIed> iedList;
}