/**
 *
 */
package com.huatek.frame.base.util;

import com.google.common.collect.Lists;
import com.huatek.frame.base.entity.DataItem;
import com.huatek.frame.base.entity.SysModelDevice;
import com.huatek.frame.base.vo.ModeTypeVO;
import lombok.Getter;

import java.util.*;

public class BusinessConstants {

    public static final Map<String, List<DataItem>> dataItemListMap = new HashMap<>();
    /**
     * 主设备类型枚举
     */
    public enum MainEquipEnum {
        BYQ("111", "变压器"),
        GIS("211", "GIS设备"),
        CW("311", "开关柜"),
        BLQ("411", "避雷器"),
        GEN("611", "发电机"),
        DL("711", "电缆"),
        ZZ("811", "主站"),
        ZNXS("911", "智能巡视");

        MainEquipEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        @Getter
        private final String value;
        @Getter
        private final String name;

        public static List<ModeTypeVO> getModelList(){
            List<ModeTypeVO> modelList = Lists.newArrayList();
            for(MainEquipEnum equipType:MainEquipEnum.values()){
                ModeTypeVO vo = new ModeTypeVO();
                vo.setModelType(equipType.getValue());
                vo.setName(equipType.getName());
                modelList.add(vo);
            }
            return modelList;
        }

    }



    /**
     * 主站设备枚举
     */
    public enum MasterStationEqmEnum {
        SWITCHING_STATION("81101", "kgz","开关站"),

        MAIN_TRANSFORMER_ROOM("81102", "zbs","主变室"),

        GENERATOR_ROOM("81103", "fdjs","发电机室"),

        HIGH_VOLTAGE_CABLE("81104", "gydl","高压电缆"),

        POWER_TRANSMISSION("81105", "cxc", "出线场");

        MasterStationEqmEnum(String value, String code, String name) {
            this.value = value;
            this.code = code;
            this.name = name;
        }

        @Getter
        private final String value;
        @Getter
        private final String code;
        @Getter
        private final String name;

        public static List<SysModelDevice> getDeviceList() {
            List<SysModelDevice> deviceList = Lists.newArrayList();
            for(MasterStationEqmEnum deviceEnum:MasterStationEqmEnum.values()){
                SysModelDevice vo = new SysModelDevice();
                vo.setModelType(deviceEnum.getValue());
                vo.setDeviceCode(deviceEnum.getCode());
                vo.setDeviceName(deviceEnum.getName());
                deviceList.add(vo);
            }
            return deviceList;
        }
    }

    /**
     * 主站装置类型枚举
     */
    public enum MasterStationDeviceTypeEnum {
        KGZ_SF6_DEVICE("8110101", "kgz_sf6zz","SF6装置"),
        KGZ_CWZZ_DEVICE("8110102", "kgz_jf","局放装置"),

        ZBZ_YSP_DEVICE("8110201", "zbs_ysp","油色谱"),
        ZBZ_TX_DEVICE("8110202", "zbs_tx","铁芯"),
        ZBZ_JJ_DEVICE("8110203", "zbs_jj","夹件"),

        FDJS_ZD_DEVICE("8110301", "fdjs_zd","振动"),
        FDJS_JF_DEVICE("8110302", "fdjs_jf","局放"),

        GYDL_CWZZ_DEVICE("8110401", "gydl_cwzz","测温装置"),
        GYDL_DLHL_DEVICE("8110402", "gydl_dlhl","电缆环流"),

        CXC_JYJC_DEVICE("8110501", "cxc_jyjc", "绝缘检测"),
        CXC_RX_DEVICE("8110502", "cxc_rx", "容性");

        MasterStationDeviceTypeEnum(String value, String code, String name) {
            this.value = value;
            this.code = code;
            this.name = name;
        }

        @Getter
        private final String value;
        @Getter
        private final String code;
        @Getter
        private final String name;

        public static List<SysModelDevice> getDeviceList() {
            List<SysModelDevice> deviceList = Lists.newArrayList();
            for(MasterStationDeviceTypeEnum deviceEnum:MasterStationDeviceTypeEnum.values()){
                SysModelDevice vo = new SysModelDevice();
                vo.setModelType(deviceEnum.getValue());
                vo.setDeviceCode(deviceEnum.getCode());
                vo.setDeviceName(deviceEnum.getName());
                deviceList.add(vo);
            }
            return deviceList;
        }
    }


    /**
     * 振动类型
     */

    public enum GeneratorAmplTypeEnum {
        kqjxx("12", "空气间隙上"),
        kqjxs("13", "空气间隙下"),
        jf("16", "局放"),
        ;

         GeneratorAmplTypeEnum(String value, String name) {
            this.value = value;
            this.name = name;
         }

        @Getter
        private final String value;
        @Getter
        private final String name;
    }

    /**
     * 1、变压器设备类型枚举
     */
    public enum TransformerEqmEnum {
        YSP_EQM("011", "ysp","油色谱"),

        JF_EQM("021", "jf","局放信号"),

        TX_EQM("031", "tx","铁芯装置"),

        HW_EQM("041", "hw","红外监测"),

        TP_EQM("051", "tp", "图片数据"),

        RX_EQM("061", "rx","容性设备"),

        QX_EQM("071", "qx","气象装置"),

        JJ_EQM("081", "jj","夹件装置"),

        RZCW_EQM("121", "rzcw","绕组测温"),

        CW_EQM("131", "cw", "测温装置"),

//        TG_EQM("091", "tg","套管装置"),   套管没有装过，暂时不考虑，

//        SJZD_EQM("101", "sjzd","声级振动"), 模型配置不进行管理

//        DLHL_EQM("111", "dlhl","电缆环流"), 文档暂无此装置

        ;

        TransformerEqmEnum(String value, String code, String name) {
            this.value = value;
            this.code = code;
            this.name = name;
        }

        @Getter
        private final String value;
        @Getter
        private final String code;
        @Getter
        private final String name;

        public static List<SysModelDevice> getDeviceList() {
            List<SysModelDevice> deviceList = Lists.newArrayList();
            for(TransformerEqmEnum deviceEnum:TransformerEqmEnum.values()){
                SysModelDevice vo = new SysModelDevice();
                vo.setModelType(MainEquipEnum.BYQ.getValue());
                vo.setDeviceCode(deviceEnum.getCode());
                vo.setDeviceName(deviceEnum.getName());
                deviceList.add(vo);
            }
            return deviceList;
        }
    }

    /**
     * 2、GIS设备类型枚举
     */
    public enum GisEqmEnum {
        JF_EQM("011", "jf", "局放信号"),

        SF6_EQM("021", "sf6","SF6"),

//        JXTX_EQM("031", "jxtx","GIS机械特性"),

        QX_EQM("041", "qx","气象装置"),

        HW_EQM("051", "hw","红外监测"),

        TP_EQM("061", "tp","图片数据"),

       SF6_ENV_EQM("071", "sf6env","SF6环境监测");

        GisEqmEnum(String value, String code, String name) {
            this.value = value;
            this.code = code;
            this.name = name;
        }

        @Getter
        private final String value;
        @Getter
        private final String code;
        @Getter
        private final String name;

        public static List<SysModelDevice> getDeviceList() {
            List<SysModelDevice> deviceList = Lists.newArrayList();
            for(GisEqmEnum deviceEnum:GisEqmEnum.values()){
                SysModelDevice vo = new SysModelDevice();
                vo.setModelType(MainEquipEnum.GIS.getValue());
                vo.setDeviceCode(deviceEnum.getCode());
                vo.setDeviceName(deviceEnum.getName());
                deviceList.add(vo);
            }
            return deviceList;
        }
    }


    /**
     * 3、避雷器设备类型枚举
     */
    public enum ArresterEqmEnum {
        JY_EQM("011", "jy","绝缘监测"),

        HW_EQM("021","hw", "红外监测"),

        RX_EQM("031", "rx", "容性设备"),

        QX_EQM("041", "qx","气象装置"),

        TP_EQM("051", "tp","图片数据");

        ArresterEqmEnum(String value, String code, String name) {
            this.value = value;
            this.code = code;
            this.name = name;
        }

        @Getter
        private final String value;
        @Getter
        private final String code;
        @Getter
        private final String name;

        public static List<SysModelDevice> getDeviceList() {
            List<SysModelDevice> deviceList = Lists.newArrayList();
            for(ArresterEqmEnum deviceEnum:ArresterEqmEnum.values()){
                SysModelDevice vo = new SysModelDevice();
                vo.setModelType(MainEquipEnum.BLQ.getValue());
                vo.setDeviceCode(deviceEnum.getCode());
                vo.setDeviceName(deviceEnum.getName());
                deviceList.add(vo);
            }
            return deviceList;
        }
    }

    /**
     * 4、电缆设备类型枚举
     */
    public enum CableEqmEnum {
        DLJF_EQM("011", "jf", "局放信号"),
        DLHL_EQM("021", "dlhl", "电缆环流"),
//        DLG_EQM("031", "dlg", "电缆沟环境"),
        HW_EQM("041", "hw", "红外监测"),
        CW_EQM("061", "cw", "测温装置");

        CableEqmEnum(String value, String code, String name) {
            this.value = value;
            this.code = code;
            this.name = name;
        }

        @Getter
        private final String value;
        @Getter
        private final String code;
        @Getter
        private final String name;

        public static List<SysModelDevice> getDeviceList() {
            List<SysModelDevice> deviceList = Lists.newArrayList();
            for(CableEqmEnum deviceEnum:CableEqmEnum.values()){
                SysModelDevice vo = new SysModelDevice();
                vo.setModelType(MainEquipEnum.DL.getValue());
                vo.setDeviceCode(deviceEnum.getCode());
                vo.setDeviceName(deviceEnum.getName());
                deviceList.add(vo);
            }
            return deviceList;
        }
    }


    /**
     * 5、开关柜设备类型枚举
     */
    public enum CabinetEqmEnum {
        CW_EQM("011", "cw", "测温装置");

        CabinetEqmEnum(String value, String code, String name) {
            this.value = value;
            this.code = code;
            this.name = name;
        }

        @Getter
        private final String value;
        @Getter
        private final String code;
        @Getter
        private final String name;

        public static List<SysModelDevice> getDeviceList() {
            List<SysModelDevice> deviceList = Lists.newArrayList();
            for(CabinetEqmEnum deviceEnum:CabinetEqmEnum.values()){
                SysModelDevice vo = new SysModelDevice();
                vo.setModelType(MainEquipEnum.CW.getValue());
                vo.setDeviceCode(deviceEnum.getCode());
                vo.setDeviceName(deviceEnum.getName());
                deviceList.add(vo);
            }
            return deviceList;
        }
    }

    /**
     * 6、发电机设备类型枚举
     */
    public enum GeneratorEqmEnum {
        ZD_EQM("011", "zd", "振动装置"),
        JF_EQM("021", "genjf", "局放信号"),
        YL_EQM("031", "genyl", "压力装置"),
        ;

        GeneratorEqmEnum(String value, String code, String name) {
            this.value = value;
            this.code = code;
            this.name = name;
        }

        @Getter
        private final String value;
        @Getter
        private final String code;
        @Getter
        private final String name;

        public static List<SysModelDevice> getDeviceList() {
            List<SysModelDevice> deviceList = Lists.newArrayList();
            for(GeneratorEqmEnum deviceEnum:GeneratorEqmEnum.values()){
                SysModelDevice vo = new SysModelDevice();
                vo.setModelType(MainEquipEnum.GEN.getValue());
                vo.setDeviceCode(deviceEnum.getCode());
                vo.setDeviceName(deviceEnum.getName());
                deviceList.add(vo);
            }
            return deviceList;
        }
    }

    /**
     *  装置枚举
     */
    public enum DeviceCodeEnum {
        // 变压器
        YSP("ysp", "油色谱"),

        JF("jf", "局放信号"),

        TX("tx", "铁芯装置"),

        HW("hw", "红外监测"),

        TP("tp", "图片数据"),

        RX("rx", "容性设备"),

        QX("qx", "气象装置"),

        JJ("jj", "夹件装置"),

        RZCW("rzcw", "绕组测温"),

        // gis
        SF6("sf6", "SF6"),
        SF6ENV("sf6env", "SF6环境监测"),

        // 避雷器
        JY("jy", "绝缘监测"),

        // 开关柜
        CW("cw", "测温装置"),

        // 电缆
        DLHL("dlhl", "电缆环流"),
//        DLG("dlg", "电缆沟环境"),

        // 发电机
        ZD("zd", "振动装置"),
        YL("genyl", "压力装置"),
        GENJF("genjf", "局放装置"),
        ;

        @Getter
        private final String value;
        @Getter
        private final String name;

        DeviceCodeEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }
    }


//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 装置数据项~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    /**
     * 变压器
     */
    // 油色谱数据项
    public enum ItemYspEnum {
        h2("h2", "氢气"),
        ch4("ch4", "甲烷"),
        c2h6("c2h6", "乙烷"),
        c2h4("c2h4", "乙烯"),
        c2h2("c2h2", "乙炔"),
        co("co", "一氧化碳"),
        co2("co2","二氧化碳"),
        o2("o2","氧气"),
        n2("n2","氮气"),
        h2o("h2o","水分"),
        total_hydrocarbon("total_hydrocarbon", "总烃"),
        tmp("tmp", "温度"),
        dew("dew", "湿度"),
        mst("mst","微水");
        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemYspEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemYspEnum item : ItemYspEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 局放数据项
    public enum ItemJfEnum {
        discharge_capacity("discharge_capacity", "放电量"),
        dsch_type("dsch_type", "放电类型"),
        dichange_count("dichange_count", "放电次数"),
        discharge_position("discharge_position", "放电位置");

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemJfEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemJfEnum item : ItemJfEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 铁芯/夹件装置
    public enum ItemTxEnum {
        total_core_current("total_core_current", "全电流(mA)");

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemTxEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemTxEnum item : ItemTxEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 红外装置
    public enum ItemHwEnum {
        max_tmp("max_tmp", "最高温度"),
        min_tmp("min_tmp", "最低温度"),
        avg_tmp("avg_tmp", "平均温度");

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemHwEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemHwEnum item : ItemHwEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 图片装置
    public enum ItemTpEnum {
        max_tmp("dataval", "表数据");

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemTpEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemTpEnum item : ItemTpEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 容性设备
    public enum ItemRxEnum {
        total_current("total_current", "泄露电流(mA)"),
        capacitance("capacitance", "电容量(pF)"),
        loss_factor("loss_factor", "介质损耗因数"),
        system_voltage("system_voltage", "系统电压(V)");

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemRxEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemRxEnum item : ItemRxEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 气象装置
    public enum ItemQxEnum {
        air_temperature("air_temperature", "气温"),
        air_pressure("air_pressure", "气压"),
        humidity("humidity", "湿度"),
        precipitation("precipitation", "降雨量"),
        precipitation_intensity("precipitation_intensity", "降水强度"),
        radiation_intensity("radiation_intensity", "光辐射强度");

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemQxEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemQxEnum item : ItemQxEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // todo 绕组测温
    public enum ItemRzcwEnum {
        tmp("max_tmp", "温度");

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemRzcwEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemRzcwEnum item : ItemRzcwEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    /**
     * GIS
     */
    // sf6
    public enum ItemSf6Enum {
        temperature("temperature", "温度(℃)"),
        moisture("moisture", "水分(μL/L)"),
        pressure20C("pressure20C", "压力(20℃)kPa");

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemSf6Enum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemSf6Enum item : ItemSf6Enum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    /**
     * SF6Env
     */
    public enum ItemSf6EnvEnum {
        tmp("tmp", "温度"),
        dew("dew", "湿度"),
        conc("conc","SF6浓度"),
        ocontent("ocontent","O2含量");
        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemSf6EnvEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemSf6EnvEnum item : ItemSf6EnvEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }
    /**
     * 避雷器
     */
    // 绝缘监测   lightningrod_im表
    public enum ItemJyEnum {
        system_voltage("system_voltage", "系统电压(V)"),
        total_current("total_current", "全电流 (mA)"),
        resistive_current("resistive_current", "阻性电流 (mA)"),
        action_count("action_count", "计数器动作次数");

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemJyEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemJyEnum item : ItemJyEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    /**
     * 开关柜(测温柜)
     */
    // 测温
    public enum ItemCwEnum {
        tmp("tmp", "温度");   // cwg_temperature

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemCwEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemCwEnum item : ItemCwEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    /**
     * 电缆
     */
    // 电缆环流
    public enum ItemDlhlEnum {

        total_core_current("total_core_current", "电流(mA）");

        @Getter
        private final String value;

        @Getter
        private final String name;

        ItemDlhlEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemDlhlEnum item : ItemDlhlEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 电缆沟环境    busi_cable_dlg
    public enum ItemDlgEnum {

        temperature("temperature", "温度"),
        humidity("humidity", "湿度"),
        a_water("a_water", "湿度"),
        smoke_alarm1("humidity", "烟雾告警1"),
        smoke_alarm2("humidity", "烟雾告警2"),
        smoke_alarm3("humidity", "烟雾告警3"),
        ;

        @Getter
        private final String value;

        @Getter
        private final String name;

        ItemDlgEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemDlgEnum item : ItemDlgEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }
    // 发电机振动(包含振动、间隙)
    public enum ItemGenZdEnum {

        ampl_x("ampl_x", "振动X轴位移"),
        ampl_y("ampl_y", "振动Y轴位移"),
        ampl_z("ampl_z", "振动Z轴位移"),
        aircap_am("aircap_am", "空气间隙0度位移"),
        aircap_bm("aircap_bm", "空气间隙90度位移"),
        aircap_cm("aircap_cm", "空气间隙180度位移"),
        aircap_dm("aircap_dm", "空气间隙270度位移"),
        ;

        @Getter
        private final String value;

        @Getter
        private final String name;

        ItemGenZdEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemGenZdEnum item : ItemGenZdEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 发电机振动(不包含间隙)
    public enum ItemGenZdZdEnum {

        ampl_x("ampl_x", "振动X轴位移"),
        ampl_y("ampl_y", "振动Y轴位移"),
        ampl_z("ampl_z", "振动Z轴位移"),
        ;

        @Getter
        private final String value;

        @Getter
        private final String name;

        ItemGenZdZdEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemGenZdZdEnum item : ItemGenZdZdEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 发电机振动(间隙)
    public enum ItemGenZdJxEnum {

        aircap_am("aircap_am", "空气间隙0度位移"),
        aircap_bm("aircap_bm", "空气间隙90度位移"),
        aircap_cm("aircap_cm", "空气间隙180度位移"),
        aircap_dm("aircap_dm", "空气间隙270度位移"),
        ;

        @Getter
        private final String value;

        @Getter
        private final String name;

        ItemGenZdJxEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemGenZdJxEnum item : ItemGenZdJxEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 发电机压力
    public enum ItemGenYlEnum {

        pv_a("pv_a", "压力1"),
        pv_b("pv_b", "压力2"),
        ;

        @Getter
        private final String value;

        @Getter
        private final String name;

        ItemGenYlEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemGenYlEnum item : ItemGenYlEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }

    // 发电机局放数据项
    public enum ItemGenJfEnum {
        discharge_capacity("discharge_capacity", "放电量"),
        dsch_type("dsch_type", "放电类型"),
        dichange_count("pulse_count", "放电次数"),
        discharge_position("discharge_position", "放电位置");

        @Getter
        private final String value;
        @Getter
        private final String name;

        ItemGenJfEnum(String value, String name) {
            this.value = value;
            this.name = name;
        }

        public static List<DataItem> getList() {
            List<DataItem> list = new ArrayList<>();
            for (ItemGenJfEnum item : ItemGenJfEnum.values()) {
                DataItem dataItem = new DataItem();
                dataItem.setItemCode(item.getValue());
                dataItem.setItemName(item.getName());
                list.add(dataItem);
            }
            return list;
        }
    }


    static {
        dataItemListMap.put("ysp", ItemYspEnum.getList());
        dataItemListMap.put("jf", ItemJfEnum.getList());
        dataItemListMap.put("tx", ItemTxEnum.getList());
        dataItemListMap.put("hw", ItemHwEnum.getList());
        dataItemListMap.put("tp", ItemTpEnum.getList());
        dataItemListMap.put("rx", ItemRxEnum.getList());
        dataItemListMap.put("qx", ItemQxEnum.getList());
        dataItemListMap.put("jj", ItemTxEnum.getList());
        dataItemListMap.put("sf6", ItemSf6Enum.getList());
        dataItemListMap.put("jy", ItemJyEnum.getList());
        dataItemListMap.put("cw", ItemCwEnum.getList());
        dataItemListMap.put("dlhl", ItemDlhlEnum.getList());
        dataItemListMap.put("dlg", ItemDlgEnum.getList());

        // 振动-振动、间隙
        dataItemListMap.put("zd", ItemGenZdEnum.getList());
        // 振动-振动
        dataItemListMap.put("genzd", ItemGenZdZdEnum.getList());
        // 振动-间隙
        dataItemListMap.put("genjx", ItemGenZdJxEnum.getList());
        // 压力
        dataItemListMap.put("genyl", ItemGenYlEnum.getList());
        // 发电机局放
        dataItemListMap.put("genjf", ItemGenJfEnum.getList());

        dataItemListMap.put("sf6env", ItemSf6EnvEnum.getList());


        dataItemListMap.put("rzcw", ItemRzcwEnum.getList());
    }


}
