package com.njcn.gather.device.pojo.enums;

import lombok.Getter;

/**
 * @author caozehui
 * @data 2024-12-12
 */
@Getter
public enum PatternEnum {
    SIMULATE("Simulate", "模拟式"),
    DIGITAL("Digital", "数字式"),
    CONTRAST("Contrast", "比对式");

    private String value;
    private String msg;

    PatternEnum(String value, String msg) {
        this.value = value;
        this.msg = msg;
    }

    public static PatternEnum getEnum(String value) {
        for (PatternEnum patternEnum : PatternEnum.values()) {
            if (patternEnum.getValue().equals(value)) {
                return patternEnum;
            }
        }
        return null;
    }
}
