package com.fastbee.iot.enums;

import com.fastbee.common.core.domain.CommonResult;

public enum WaterFertilizerHttpEnum {
    _08012101("08012101", "参数不足"),
    _08010001("08010001", "设备不存在或云服务器不存在"),
    _08010002("08010002", "设备不存在或云服务器不存在"),
    _08012102("08012102", "私钥不正确"),
    _08012103("08012103", "解密失败"),
    _08012104("08012104", "超时过期"),
    _08010003("08010003", "操作失败"),
    _08012105("08012105", "操作失败"),
    _08012106("08012106", "与设备通信失败");

    private String name;
    private String type;


    WaterFertilizerHttpEnum(String type, String name) {
        this.type = type;
        this.name = name;
    }

    public static WaterFertilizerHttpEnum getWaterFertilizerHttpEnum(String type) {
        for (WaterFertilizerHttpEnum scoreEnum : WaterFertilizerHttpEnum.values()) {
            if (scoreEnum.type.equals(type)) {
                return scoreEnum;
            }
        }
        return null;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }
}
