package com.iformall.enums;

public enum EnumBusRatioTime {
    YEAR(1, "年"),
    MONTH(2, "月"),
    PERIOD(3,"周期"),
    ;

    public static EnumBusRatioTime getEnum(Integer code) {
        for (EnumBusRatioTime value : values()) {
            if (value.getCode().equals(code)) {
                return value;
            }
        }
        return null;
    }

    private Integer code;
    private String message;

    EnumBusRatioTime(Integer code, String message) {
        this.code = code;
        this.message = message;
    }

    public Integer getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }
}
