package com.yeejoin.amos.boot.module.hygf.api.Enum;



public enum PVProducerInfoEnum {

    GDW("固德威","GOODWE"),
    SH("首航","SH"),
    JLY("锦浪云","JLY"),
    KSOLAR("科士达","KSD"),
    YG("阳光","YG"),
    HUAWEI("华为","HW"),
    TANYIN("碳银","TY");
    private String name;


    private String code;

    public String getName() {
        return name;
    }
    PVProducerInfoEnum(String name, String code) {
        this.name = name;
        this.code = code;
    }

    public static String getNameByCode(String code) {
        String name = null;
        for(PVProducerInfoEnum type: PVProducerInfoEnum.values()) {
            if (type.getCode().equals(code)) {
                name = type.getName();
                break;
            }
        }
        return name;
    }
    public void setName(String name) {
        this.name = name;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }
}
