package com.qmth.exam.reserve.enums;

import lombok.AllArgsConstructor;
import lombok.Getter;

@Getter
@AllArgsConstructor
public enum ImportStatus {

    RUNNING("正在导入"),

    SUCCESS("导入成功"),

    FAILURE("导入失败");

    private String name;

    public static ImportStatus getByName(String name) {
        for (ImportStatus r : ImportStatus.values()) {
            if (r.getName().equals(name)) {
                return r;
            }
        }
        return null;
    }

    public static void main(String[] args) {
        System.out.println(ImportStatus.SUCCESS.name);
    }
}
