package com.jwipc.constant;

import lombok.Getter;

/**
 * <p> </p>
 *
 * @author ZhangJie
 * @version 1.0
 * @since JDK 1.8
 */
@Getter
public enum FlagConst {
    Y(1,"是","Y")
    ,N(0,"否","N")
    ,R(2,"驳回","R");

    private Integer code;
    private String msg;
    private String label;

    FlagConst(Integer code, String msg,String label) {
        this.code = code;
        this.msg = msg;
        this.label = label;
    }

    public static FlagConst getFlag(int code){
        for (FlagConst value : FlagConst.values()) {
            if(value.getCode()==code){
                return value;
            }
        }
        return null;
    }
}
