package com.qmth.file.enums;

/**
 * 机考 考试计划 状态
 * @author tianjun
 *
 */
public enum ExamStatus {

	UN_PUBLISHED("未发布", 0), PUBLISHED("已发布", 1);

    private String name;

    private int id;

    private ExamStatus(String name, int id) {
        this.name = name;
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public int getId() {
        return id;
    }

    public static ExamStatus findById(int id) {
        for (ExamStatus status : ExamStatus.values()) {
            if (status.id == id) {
                return status;
            }
        }
        return null;
    }

}
