package com.qmth.distributed.print.business.enums;

import com.qmth.teachcloud.common.enums.EnumResult;

import java.util.ArrayList;
import java.util.List;

/**
 * 考试试卷结构同步状态
 */
public enum ExamPrintPlanSyncStatusEnum {

    INIT("未开始"),
    START_SYNC("开始同步"),
    EXAM_FINISH("考试同步成功"),
    STUDENT_FINISH("考生同步成功"),
    FINISH("题卡同步成功，已结束");

    ExamPrintPlanSyncStatusEnum(String desc) {
        this.desc = desc;
    }

    private String desc;

    public String getDesc() {
        return desc;
    }

    /**
     * @return
     */
    public static List<EnumResult> listTypes() {
        List<EnumResult> list = new ArrayList<EnumResult>();
        for (ExamPrintPlanSyncStatusEnum value : ExamPrintPlanSyncStatusEnum.values()) {
            EnumResult result = new EnumResult();
            result.setName(value.name());
            result.setOrdinal(value.ordinal());
            result.setCode(null);
            result.setDesc(value.getDesc());
            list.add(result);
        }
        return list;
    }

}
