files v2 controller without impl

feature/configv2
prplV 2025-04-10 08:53:52 -04:00
parent 2b82fb7aac
commit f504632c4d
1 changed files with 18 additions and 0 deletions

View File

@ -5,7 +5,25 @@ use std::borrow::BorrowMut;
use std::path::Path;
use std::sync::Arc;
use tokio::sync::mpsc;
use tokio::sync::mpsc::Sender as MpscSender;
use tokio::time::Duration;
use crate::options::structs::Events;
pub mod v2 {
use std::collections::HashMap;
use crate::options::structs::Triggers;
use super::*;
struct FilesController<'a> {
name: &'a str,
watcher: Inotify,
// obj: Arc<Files>,
triggers: HashMap<&'a str, Triggers<'a>>,
event_registrator: Vec<MpscSender<Events<'a>>>,
}
}
/// # Fn `create_watcher`
/// ## for creating watcher on file's delete | update events