package com.hh.lib_record.bean;

/**
 * Description: 麦克风类型
 * @author xwh
 * time 2024/12/13
 **/
public enum MicrophoneTypeEnum {
    NATIVE_AUDI0(1),ASR(2);

    private int value;
    MicrophoneTypeEnum(int value){
        this.value = value;
    }
    public int getValue() {
        return value;
    }

    public static MicrophoneTypeEnum fromValue(int value) {
        for (MicrophoneTypeEnum type : MicrophoneTypeEnum.values()) {
            if (type.getValue() == value) {
                return type;
            }
        }
        return NATIVE_AUDI0; // 或者抛出一个异常，如果你确定这种情况不应该发生
    }
}
