package com.iformall.enums;

/**
 * Created by Stormeye on 2018/08/09.
 */
public enum EnumScreenAdType {

    COUPON(0, "券"),
    CAMPAIGN(1, "宣传页"),
    PICTURE(2, "图片"),
    MERCHANT(3, "商户");

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

    private Integer code;
    private String message;

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

    public Integer getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }
}
