package com.its.bis.dto;

import com.its.bis.entity.TbVmsCtlrStts;
import io.netty.channel.Channel;
import lombok.*;
import lombok.extern.slf4j.Slf4j;

import java.io.Serializable;
import java.net.InetSocketAddress;

@Slf4j
@Getter
@Setter
@ToString
@Builder
@NoArgsConstructor//(access = AccessLevel.PROTECTED)
@AllArgsConstructor
public class TbVmsCtlrDto implements Serializable {
    private static final long serialVersionUID = 1L;

    private int  index;
    private Long vmsCtlrNmbr;
    private Long groupNo;
    private Integer ctlrLocalNo;
    private String ctlrId;
    private String name;
    private String ctlrIp;
    private String ctlrPort;
    private String usagTypeCd;
    private String frmTypeCd;
    private String typeCd;
    private String modlTypeCd;
    private String operMode;
    private Integer cmncfailSlotNmbr;
    private Integer pwerFailSlotNmbr;
    private String cmtrinfrCnctYn;
    private String wthrinfrCnctYn;
    private String envrinfrCnctYn;
    private Integer maxPhaseNum;
    private String istlLctnNm;
    private String istlLctnAddr;
    private String trfcStrgUseYn;
    private Long locIfscId;

    private Integer defPhseChngCycl;    // 기본메시지주기
    private String panlOnTime;          // 전광판 ON TIME
    private String panlOffTime;         // 전광판 OFF TIME
    private Integer panlPwerMode;        // 전광판 전원 모드(0x00:꺼짐,0x01:켜짐,0x02:자동,0x09:알수없음)
    private Integer fanMode;            // FAN 동작모드(0x00:꺼짐,0x01:켜짐,0x02:자동,0x09:알수없음)
    private Integer fanRunTmpr;          // 팬 동작 온도
    private Integer hetrMode;           // 히터 동작모드(0x00:꺼짐,0x01:켜짐,0x02:자동,0x09:알수없음)
    private Integer hetrRunTmpr;         // 히터 동작 온도
    private Integer brghMode;           // 휘도 모드(0x00:주간,0x01:야간,0x02:자동,0x09:수동)
    private Integer brghCurrStep;       // 휘도 현재 단계(0~100)
    private Integer brghWeekStep;       // 휘도 주간 단계(0~100)
    private Integer brghNghtStep;       // 휘도 야간 단계(0~100)
    private Integer modlErrRate;        // VMS 모듈 오류 율
    private Integer cmncFailRate;       // VMS 통신 오류 기본 값

    private Integer protocolVer;
    private String delYn;

    private int vmsWidth;
    private int vmsHeight;
    private int modlRowNum;
    private int modlColNum;
    private int powrRowNum;
    private int powrColNum;

    private String localFormDir;
    private String ftpFormDir;
    private boolean ftpDownload;
    private boolean symbolDownload;

    private int maxCngstForm;        // 정체폼 생성 최대 갯수
    private int cngstForms;
    private boolean existCngsForm;
    private boolean provide;
    private boolean evehIngForm;
    private boolean evehEndForm;

    private byte txtOpCode;

    private TbVmsCtlrStts     stts;
    private int 			  netState;
    private boolean           isDupCon;
    private boolean           isDupLogin;
    private String 		      dstIpAddr;
    private Channel           channel = null;
    private Channel           dupChannel = null;
    private InetSocketAddress cliReq;
    private long              syncTime;

    public String getLogKey() {
        return this.ctlrId;
    }

}

