去除通用策略生成监督数据逻辑

This commit is contained in:
Lee
2023-03-23 16:12:14 +08:00
parent 0711f76f60
commit 211e0191a4
9 changed files with 267 additions and 131 deletions

View File

@@ -0,0 +1,26 @@
package com.njcn.prepare.enums;
import lombok.Getter;
@Getter
public enum AlarmTypeEnum {
EARLY_WARN(0, "电能质量技术预警单"),
REPORT_WARN(1, "电能质量技术告警单");
private final Integer code;
private final String message;
AlarmTypeEnum(Integer code, String message) {
this.code = code;
this.message = message;
}
public static AlarmTypeEnum getAlarmTypeEnumByCode(Integer code) {
for (AlarmTypeEnum alarmTypeEnum : AlarmTypeEnum.values()) {
if (alarmTypeEnum.getCode().equals(code)) {
return alarmTypeEnum;
}
}
return null;
}
}

View File

@@ -9,14 +9,14 @@ import org.apache.commons.lang3.StringUtils;
@Getter
public enum SteadyIndicatorEnum {
Negative_Voltage("Negative_Voltage", "负序电压不平衡度"),
Interhar_Voltage("Interhar_Voltage", "间谐波电压"),
Neg_Current("Neg_Current", "负序电流"),
Fre_Deviation("Fre_Deviation", "频率偏差"),
Voltage_Dev("Voltage_Dev", "电压偏差"),
Har_Current("Har_Current", "谐波电流"),
Voltage_Fluc("Voltage_Fluc", "电压波动与闪变"),
Har_Voltage("Har_Voltage", "谐波电压");
Negative_Voltage("Negative_Voltage", "负序电压不平衡度越限"),
Interhar_Voltage("Interhar_Voltage", "间谐波电压越限"),
Neg_Current("Neg_Current", "负序电流越限"),
Fre_Deviation("Fre_Deviation", "频率偏差越限"),
Voltage_Dev("Voltage_Dev", "电压偏差越限"),
Har_Current("Har_Current", "谐波电流越限"),
Voltage_Fluc("Voltage_Fluc", "电压波动与闪变越限"),
Har_Voltage("Har_Voltage", "谐波电压越限");
private final String code;