package com.sw.mes.yb.pad.dto;

import lombok.Data;

import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.List;

@Data
public class LineDetailedDto implements Comparable<LineDetailedDto> {
    /**
     * 0：晶段，1：样片，2：回收料-孪晶，3：回收料-直径
     */
    int type;
    int length;
    String segmentNo;
    int sequence;
    String remark;
    /**
     * 段号
     */
    Integer segmentNum;
    /**
     * 样片类型
     */
    Integer sampleType;

    /**
     * 晶线分叉【0：默认，否；1：是；】
     */
    Boolean isFork;

    /**
     * 扭
     */
    BigDecimal distortion;

    /**
     * 是否带彩 默认 否
     */
    Boolean colorful = false;

    private List<DrawLineExceptionDto> exceptionDtos = new ArrayList();

    public LineDetailedDto() {
    }

    public LineDetailedDto(int type, int length) {
        this.type = type;
        this.length = length;
    }


    @Override
    public int compareTo(LineDetailedDto o) {

        return new Integer(o.getSequence()).compareTo(new Integer(this.getSequence()));
    }
}
