package com.iformall.enums;

public enum EnumScoreRules {

    SCORE(1, "成长值"),
    CREDIT(2, "积分")
    ;

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

    private Integer code;
    private String message;

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

    public Integer getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }
}
