package cgmblelib.Enum;


import com.mytatvarnsdk.R;

/**
 * Created by minyuchun on 2019/2/25.
 * 媒体声音
 * @author minyuchun
 */

public enum enumSound {
      /**
     * 报警声音默认
     */
    NONE(0,0),
    /**
     *  报警声音2
     */
    HIGH(1, R.raw.high_alarm),
    /**
     * 报警声音1
     */
    MEDIUM(2,R.raw.medium_alarm)
    ;

    private int soundId;

    private int soundRawId;

    enumSound(int soundId, int soundRawId) {
        this.soundId = soundId;
        this.soundRawId = soundRawId;
    }

    public int getSoundId() {
        return soundId;
    }

    public int getSoundRawId() {
        return soundRawId;
    }

    public static enumSound getEnumSound(int soundId){
        for (enumSound e : enumSound.values()) {
            if (soundId == e.getSoundId()) {
                return e;
            }
        }
        return NONE;
    }


}
