package com.ningdatech.pmapi.common.enumeration;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * @author liuxinxin
 * @date 2022/7/26 上午9:21
 */
@AllArgsConstructor
@Getter
public enum BoolDisplayEnum {

    /**
     * true
     */
    Y,

    /**
     * false
     */
    N;

    public static boolean judgeBoolean(String key) {
        return Y.name().equals(key);
    }

    public static BoolDisplayEnum judgeBoolean(boolean key) {
        return key ? Y : N;
    }

}
