package cn.com.qmth.stmms.common.enums;

public enum ExamSubjectStatus {

    MARKING("评卷", 0), PAUSE("暂停", 1), FINISH("结束", 2);

    private String name;

    private int value;

    private ExamSubjectStatus(String name, int value) {
        this.name = name;
        this.value = value;
    }

    public String getName() {
        return name;
    }

    public int getValue() {
        return value;
    }

    public static ExamSubjectStatus findByValue(int value) {
        ExamSubjectStatus status = null;
        for (ExamSubjectStatus s : ExamSubjectStatus.values()) {
            if (s.getValue() == value) {
                status = s;
                break;
            }
        }
        return status;
    }
}
