Files

22 lines
417 B
Rust

use dsp_thomann::dsp408::DSP408;
use std::collections::HashMap;
use std::sync::{Arc, Mutex};
pub struct DSPDevice {
pub dsp: DSP408,
}
pub struct AppState {
pub devices: Mutex<HashMap<u64, Arc<Mutex<DSPDevice>>>>,
pub next_id: Mutex<u64>,
}
impl AppState {
pub fn new() -> Self {
Self {
devices: Mutex::new(HashMap::new()),
next_id: Mutex::new(1),
}
}
}