diff --git a/src/main.rs b/src/main.rs index 19ae35c..25bc642 100644 --- a/src/main.rs +++ b/src/main.rs @@ -17,6 +17,7 @@ mod error; mod machine; mod connection; mod registries; +mod network; use signal_hook::iterator::Signals; diff --git a/src/network.rs b/src/network.rs index c6340f3..e9d0e6b 100644 --- a/src/network.rs +++ b/src/network.rs @@ -19,7 +19,15 @@ impl Network { /// /// Idea being that bffh builds an event network that filters an incoming event into an /// the appropiate (sub)set of signal handlers based on pretty dynamic configuration. - pub fn filter bool>(&mut self) { + pub fn filter, F: Fn(&B) -> bool>(&mut self, ) { unimplemented!() } } + +enum Event { + +} + +trait Filter { + fn filter(&self, f: Fn(&S) -> bool); +}